Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1452550 > unrolled thread
| Started by | Maxime Ripard <maxime.ripard@free-electrons.com> |
|---|---|
| First post | 2016-07-29 22:30 +0200 |
| Last post | 2016-07-30 19:40 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH v3 00/13] sunxi spi fixes Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-07-29 22:30 +0200
Re: [PATCH v3 00/13] sunxi spi fixes Michal Suchanek <hramrach@gmail.com> - 2016-07-30 19:40 +0200
| From | Maxime Ripard <maxime.ripard@free-electrons.com> |
|---|---|
| Date | 2016-07-29 22:30 +0200 |
| Subject | Re: [PATCH v3 00/13] sunxi spi fixes |
| Message-ID | <s0mzT-157-3@gated-at.bofh.it> |
[Multipart message — attachments visible in raw view] — view raw
On Mon, Jul 25, 2016 at 10:03:14AM +0200, Michal Suchanek wrote: > Hello, > > On 25 July 2016 at 09:32, Maxime Ripard > <maxime.ripard@free-electrons.com> wrote: > > On Fri, Jun 17, 2016 at 12:34:44PM +0200, Michal Suchanek wrote: > >> Hello, > >> > >> On 13 June 2016 at 21:57, Maxime Ripard > >> <maxime.ripard@free-electrons.com> wrote: > >> > On Mon, Jun 13, 2016 at 05:46:48PM -0000, Michal Suchanek wrote: > >> >> Hello, > >> >> > >> >> This is update of the sunxi spi patches that should give full-featured SPI > >> >> driver. > >> >> > >> >> First three patches fix issues with the current driver and can be of use for > >> >> stable kernels so adding cc for those. > >> >> > >> >> I merged the sun4i and sun6i driver because there several issues that need to > >> >> be fixed in both separately and they are even out of sync wrt some fixes. > >> >> I guess some of the merge patches can be squashed. > >> >> > >> >> I tested this with A10s Olinuxino Micro. I have no sun6i device so I cannot > >> >> tell if that side was broken by this patchset - especially the last patch that > >> >> adds DMA was afaik never tested on sun6i. > >> > > >> > > >> > For the record, I'm still very much opposed to such a merge. > >> > >> What is the reason against the merge? I did not find the original > >> discussion. > > > > I really prefer some code that is concise and clear but a little > > duplicated over some code that shares every possible lines of code but > > is a giant mess impossible to understand. > > Yes, it's been tried. In the case of this driver there is more duplication > than differences. Also bitrot due to different variants receiving different > updates and fixes crept in already. > > Adding the remap layer certainly does not make the driver easier to > understand but it's not becoming giant mess either. Well, when you say that you're not quite fond of using your structure all over the place because "it makes your eyes bleed", I wouldn't call that a good sales pitch. But again, reg_field seems like a good solution for that. Maxime -- Maxime Ripard, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com
[toc] | [next] | [standalone]
| From | Michal Suchanek <hramrach@gmail.com> |
|---|---|
| Date | 2016-07-30 19:40 +0200 |
| Message-ID | <s0GoV-5si-7@gated-at.bofh.it> |
| In reply to | #1452550 |
On 29 July 2016 at 22:22, Maxime Ripard <maxime.ripard@free-electrons.com> wrote: > On Mon, Jul 25, 2016 at 10:03:14AM +0200, Michal Suchanek wrote: >> Hello, >> >> On 25 July 2016 at 09:32, Maxime Ripard >> <maxime.ripard@free-electrons.com> wrote: >> > On Fri, Jun 17, 2016 at 12:34:44PM +0200, Michal Suchanek wrote: >> >> Hello, >> >> >> >> On 13 June 2016 at 21:57, Maxime Ripard >> >> <maxime.ripard@free-electrons.com> wrote: >> >> > On Mon, Jun 13, 2016 at 05:46:48PM -0000, Michal Suchanek wrote: >> >> >> Hello, >> >> >> >> >> >> This is update of the sunxi spi patches that should give full-featured SPI >> >> >> driver. >> >> >> >> >> >> First three patches fix issues with the current driver and can be of use for >> >> >> stable kernels so adding cc for those. >> >> >> >> >> >> I merged the sun4i and sun6i driver because there several issues that need to >> >> >> be fixed in both separately and they are even out of sync wrt some fixes. >> >> >> I guess some of the merge patches can be squashed. >> >> >> >> >> >> I tested this with A10s Olinuxino Micro. I have no sun6i device so I cannot >> >> >> tell if that side was broken by this patchset - especially the last patch that >> >> >> adds DMA was afaik never tested on sun6i. >> >> > >> >> > >> >> > For the record, I'm still very much opposed to such a merge. >> >> >> >> What is the reason against the merge? I did not find the original >> >> discussion. >> > >> > I really prefer some code that is concise and clear but a little >> > duplicated over some code that shares every possible lines of code but >> > is a giant mess impossible to understand. >> >> Yes, it's been tried. In the case of this driver there is more duplication >> than differences. Also bitrot due to different variants receiving different >> updates and fixes crept in already. >> >> Adding the remap layer certainly does not make the driver easier to >> understand but it's not becoming giant mess either. > > Well, when you say that you're not quite fond of using your structure > all over the place because "it makes your eyes bleed", I wouldn't call > that a good sales pitch. That's why put dereferencing it inside the read function. It reduces the noise throughout the code and make it easier to add checks or change the remap implementation. > > But again, reg_field seems like a good solution for that. I will look at reg_field. I saw some drivers using remap layers that are way more heavyweight than looking up an integer in a table so I wanted to avoid that. Thanks Michal
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web