mbox series

[V4,00/13] net: smc911x: Convert to DM

Message ID 20200325164653.112079-1-marek.vasut+renesas@gmail.com
Headers show
Series net: smc911x: Convert to DM | expand

Message

Marek Vasut March 25, 2020, 4:46 p.m. UTC
Perform DM conversion of the SMC911x driver.

Note that the DT compatible is set only for 9115 , so this might need
to be changed.

Marek Vasut (13):
  net: smc911x: Remove pkt_data_{push,pull}
  net: smc911x: Replace malloc()+memset() with calloc()
  net: smc911x: Rename smc911x_rx() to smc911x_recv()
  net: smc911x: Invert the logic in smc911x_miiphy_{read,write}()
  net: smc911x: Fix potential memleak() in init fail path
  net: smc911x: Pull MII registration into separate function
  net: smc911x: Inline all functions from header file
  net: smc911x: Drop weak alias from 32bit accessors
  net: smc911x: Convert IO accessors to {read,write}{w,l}()
  net: smc911x: Pass around driver private data
  net: smc911x: Clean up the status handling in smc911x_recv()
  net: smc911x: Split non-DM specific bits from common code
  net: smc911x: Add DM support

 drivers/net/Kconfig                  |   2 +
 drivers/net/smc911x.c                | 559 +++++++++++++++++++++------
 drivers/net/smc911x.h                | 157 --------
 examples/standalone/Makefile         |   5 +-
 examples/standalone/smc911x_eeprom.c | 150 +++++++
 5 files changed, 602 insertions(+), 271 deletions(-)

Cc: Joe Hershberger <joe.hershberger at ni.com>
Cc: Masahiro Yamada <yamada.masahiro at socionext.com>

Comments

Adam Ford March 26, 2020, 10:47 a.m. UTC | #1
On Wed, Mar 25, 2020 at 11:47 AM Marek Vasut <marek.vasut at gmail.com> wrote:
>
> Perform DM conversion of the SMC911x driver.
>
> Note that the DT compatible is set only for 9115 , so this might need
> to be changed.
>
> Marek Vasut (13):
>   net: smc911x: Remove pkt_data_{push,pull}
>   net: smc911x: Replace malloc()+memset() with calloc()
>   net: smc911x: Rename smc911x_rx() to smc911x_recv()
>   net: smc911x: Invert the logic in smc911x_miiphy_{read,write}()
>   net: smc911x: Fix potential memleak() in init fail path
>   net: smc911x: Pull MII registration into separate function
>   net: smc911x: Inline all functions from header file
>   net: smc911x: Drop weak alias from 32bit accessors
>   net: smc911x: Convert IO accessors to {read,write}{w,l}()
>   net: smc911x: Pass around driver private data
>   net: smc911x: Clean up the status handling in smc911x_recv()
>   net: smc911x: Split non-DM specific bits from common code
>   net: smc911x: Add DM support
>
>  drivers/net/Kconfig                  |   2 +
>  drivers/net/smc911x.c                | 559 +++++++++++++++++++++------
>  drivers/net/smc911x.h                | 157 --------
>  examples/standalone/Makefile         |   5 +-
>  examples/standalone/smc911x_eeprom.c | 150 +++++++
>  5 files changed, 602 insertions(+), 271 deletions(-)
>
> Cc: Joe Hershberger <joe.hershberger at ni.com>
> Cc: Masahiro Yamada <yamada.masahiro at socionext.com>

For the series:
Tested-by: Adam Ford <aford173 at gmail.com> #omap3_logic
>
> --
> 2.25.1
>
Marek Vasut March 26, 2020, 10:51 a.m. UTC | #2
On 3/26/20 11:47 AM, Adam Ford wrote:
> On Wed, Mar 25, 2020 at 11:47 AM Marek Vasut <marek.vasut at gmail.com> wrote:
>>
>> Perform DM conversion of the SMC911x driver.
>>
>> Note that the DT compatible is set only for 9115 , so this might need
>> to be changed.
>>
>> Marek Vasut (13):
>>   net: smc911x: Remove pkt_data_{push,pull}
>>   net: smc911x: Replace malloc()+memset() with calloc()
>>   net: smc911x: Rename smc911x_rx() to smc911x_recv()
>>   net: smc911x: Invert the logic in smc911x_miiphy_{read,write}()
>>   net: smc911x: Fix potential memleak() in init fail path
>>   net: smc911x: Pull MII registration into separate function
>>   net: smc911x: Inline all functions from header file
>>   net: smc911x: Drop weak alias from 32bit accessors
>>   net: smc911x: Convert IO accessors to {read,write}{w,l}()
>>   net: smc911x: Pass around driver private data
>>   net: smc911x: Clean up the status handling in smc911x_recv()
>>   net: smc911x: Split non-DM specific bits from common code
>>   net: smc911x: Add DM support
>>
>>  drivers/net/Kconfig                  |   2 +
>>  drivers/net/smc911x.c                | 559 +++++++++++++++++++++------
>>  drivers/net/smc911x.h                | 157 --------
>>  examples/standalone/Makefile         |   5 +-
>>  examples/standalone/smc911x_eeprom.c | 150 +++++++
>>  5 files changed, 602 insertions(+), 271 deletions(-)
>>
>> Cc: Joe Hershberger <joe.hershberger at ni.com>
>> Cc: Masahiro Yamada <yamada.masahiro at socionext.com>
> 
> For the series:
> Tested-by: Adam Ford <aford173 at gmail.com> #omap3_logic

Cool, thanks.

Do you plan to convert the OMAP boards to this then ?
Adam Ford March 26, 2020, 10:59 a.m. UTC | #3
On Thu, Mar 26, 2020 at 5:51 AM Marek Vasut <marek.vasut at gmail.com> wrote:
>
> On 3/26/20 11:47 AM, Adam Ford wrote:
> > On Wed, Mar 25, 2020 at 11:47 AM Marek Vasut <marek.vasut at gmail.com> wrote:
> >>
> >> Perform DM conversion of the SMC911x driver.
> >>
> >> Note that the DT compatible is set only for 9115 , so this might need
> >> to be changed.
> >>
> >> Marek Vasut (13):
> >>   net: smc911x: Remove pkt_data_{push,pull}
> >>   net: smc911x: Replace malloc()+memset() with calloc()
> >>   net: smc911x: Rename smc911x_rx() to smc911x_recv()
> >>   net: smc911x: Invert the logic in smc911x_miiphy_{read,write}()
> >>   net: smc911x: Fix potential memleak() in init fail path
> >>   net: smc911x: Pull MII registration into separate function
> >>   net: smc911x: Inline all functions from header file
> >>   net: smc911x: Drop weak alias from 32bit accessors
> >>   net: smc911x: Convert IO accessors to {read,write}{w,l}()
> >>   net: smc911x: Pass around driver private data
> >>   net: smc911x: Clean up the status handling in smc911x_recv()
> >>   net: smc911x: Split non-DM specific bits from common code
> >>   net: smc911x: Add DM support
> >>
> >>  drivers/net/Kconfig                  |   2 +
> >>  drivers/net/smc911x.c                | 559 +++++++++++++++++++++------
> >>  drivers/net/smc911x.h                | 157 --------
> >>  examples/standalone/Makefile         |   5 +-
> >>  examples/standalone/smc911x_eeprom.c | 150 +++++++
> >>  5 files changed, 602 insertions(+), 271 deletions(-)
> >>
> >> Cc: Joe Hershberger <joe.hershberger at ni.com>
> >> Cc: Masahiro Yamada <yamada.masahiro at socionext.com>
> >
> > For the series:
> > Tested-by: Adam Ford <aford173 at gmail.com> #omap3_logic
>
> Cool, thanks.
>
> Do you plan to convert the OMAP boards to this then ?

Once your patch has been accepted, I will convert the boards that I
maintain.  The way you set it up shows they work using the non-DM and
DM options.  I have verified it on mine using both, but I don't have
the other hardware to verify the functionality, but I'll try to CC a
variety of omap people that I know of so they are aware.

adam
Marek Vasut March 26, 2020, 1:07 p.m. UTC | #4
On 3/26/20 11:59 AM, Adam Ford wrote:
> On Thu, Mar 26, 2020 at 5:51 AM Marek Vasut <marek.vasut at gmail.com> wrote:
>>
>> On 3/26/20 11:47 AM, Adam Ford wrote:
>>> On Wed, Mar 25, 2020 at 11:47 AM Marek Vasut <marek.vasut at gmail.com> wrote:
>>>>
>>>> Perform DM conversion of the SMC911x driver.
>>>>
>>>> Note that the DT compatible is set only for 9115 , so this might need
>>>> to be changed.
>>>>
>>>> Marek Vasut (13):
>>>>   net: smc911x: Remove pkt_data_{push,pull}
>>>>   net: smc911x: Replace malloc()+memset() with calloc()
>>>>   net: smc911x: Rename smc911x_rx() to smc911x_recv()
>>>>   net: smc911x: Invert the logic in smc911x_miiphy_{read,write}()
>>>>   net: smc911x: Fix potential memleak() in init fail path
>>>>   net: smc911x: Pull MII registration into separate function
>>>>   net: smc911x: Inline all functions from header file
>>>>   net: smc911x: Drop weak alias from 32bit accessors
>>>>   net: smc911x: Convert IO accessors to {read,write}{w,l}()
>>>>   net: smc911x: Pass around driver private data
>>>>   net: smc911x: Clean up the status handling in smc911x_recv()
>>>>   net: smc911x: Split non-DM specific bits from common code
>>>>   net: smc911x: Add DM support
>>>>
>>>>  drivers/net/Kconfig                  |   2 +
>>>>  drivers/net/smc911x.c                | 559 +++++++++++++++++++++------
>>>>  drivers/net/smc911x.h                | 157 --------
>>>>  examples/standalone/Makefile         |   5 +-
>>>>  examples/standalone/smc911x_eeprom.c | 150 +++++++
>>>>  5 files changed, 602 insertions(+), 271 deletions(-)
>>>>
>>>> Cc: Joe Hershberger <joe.hershberger at ni.com>
>>>> Cc: Masahiro Yamada <yamada.masahiro at socionext.com>
>>>
>>> For the series:
>>> Tested-by: Adam Ford <aford173 at gmail.com> #omap3_logic
>>
>> Cool, thanks.
>>
>> Do you plan to convert the OMAP boards to this then ?
> 
> Once your patch has been accepted, I will convert the boards that I
> maintain.  The way you set it up shows they work using the non-DM and
> DM options.

I had to, to avoid breaking various boards.

> I have verified it on mine using both, but I don't have
> the other hardware to verify the functionality, but I'll try to CC a
> variety of omap people that I know of so they are aware.

Good, thanks.