lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <07456b90-a83c-b1b9-20d4-b70a746148a5@infradead.org>
Date:   Wed, 3 Nov 2021 13:26:12 -0700
From:   Randy Dunlap <rdunlap@...radead.org>
To:     Wells Lu 呂芳騰 <wells.lu@...plus.com>,
        Wells Lu <wellslutw@...il.com>,
        "davem@...emloft.net" <davem@...emloft.net>,
        "kuba@...nel.org" <kuba@...nel.org>,
        "robh+dt@...nel.org" <robh+dt@...nel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "p.zabel@...gutronix.de" <p.zabel@...gutronix.de>
Subject: Re: [PATCH 2/2] net: ethernet: Add driver for Sunplus SP7021

On 11/3/21 11:08 AM, Wells Lu 呂芳騰 wrote:
>>
>> Hi--
>>
>> On 11/3/21 4:02 AM, Wells Lu wrote:
>>> diff --git a/drivers/net/ethernet/sunplus/Kconfig
>>> b/drivers/net/ethernet/sunplus/Kconfig
>>> new file mode 100644
>>> index 0000000..a9e3a4c
>>> --- /dev/null
>>> +++ b/drivers/net/ethernet/sunplus/Kconfig
>>> @@ -0,0 +1,20 @@
>>> +# SPDX-License-Identifier: GPL-2.0
>>> +#
>>> +# Sunplus Ethernet device configuration #
>>> +
>>> +config NET_VENDOR_SUNPLUS
>>> +	tristate "Sunplus Dual 10M/100M Ethernet (with L2 switch) devices"
>>> +	depends on ETHERNET && SOC_SP7021
>>> +	select PHYLIB
>>> +	select PINCTRL_SPPCTL
>>> +	select COMMON_CLK_SP7021
>>> +	select RESET_SUNPLUS
>>> +	select NVMEM_SUNPLUS_OCOTP
>>> +	help
>>> +	  If you have Sunplus dual 10M/100M Ethernet (with L2 switch)
>>> +	  devices, say Y.
>>> +	  The network device supports dual 10M/100M Ethernet interfaces,
>>> +	  or one 10/100M Ethernet interface with two LAN ports.
>>> +	  To compile this driver as a module, choose M here.  The module
>>> +	  will be called sp_l2sw.
>>
>> Please use NET_VENDOR_SUNPLUS in the same way that other
>> NET_VENDOR_wyxz kconfig symbols are used. It should just enable or
>> disable any specific device drivers under it.
>>
>>
>> --
>> ~Randy
> 
> I looked up Kconfig file of other vendors, but not sure what I should do.
> Do I need to modify Kconfig file in the form as shown below?

Hi,

Yes, this is the correct general idea, but also consider
Andrew's comments.

Thanks.

> # SPDX-License-Identifier: GPL-2.0
> #
> # Sunplus device configuration
> #
> 
> config NET_VENDOR_SUNPLUS
> 	bool "Sunplus devices"
> 	default y
> 	depends on ARCH_SUNPLUS
> 	---help---
> 	  If you have a network (Ethernet) card belonging to this
> 	  class, say Y here.
> 
> 	  Note that the answer to this question doesn't directly
> 	  affect the kernel: saying N will just cause the configurator
> 	  to skip all the questions about Sunplus cards. If you say Y,
> 	  you will be asked for your specific card in the following
> 	  questions.
> 
> if NET_VENDOR_SUNPLUS
> 
> config SP7021_EMAC
> 	tristate "Sunplus Dual 10M/100M Ethernet (with L2 switch) devices"
> 	depends on ETHERNET && SOC_SP7021
> 	select PHYLIB
> 	select PINCTRL_SPPCTL
> 	select COMMON_CLK_SP7021
> 	select RESET_SUNPLUS
> 	select NVMEM_SUNPLUS_OCOTP
> 	help
> 	  If you have Sunplus dual 10M/100M Ethernet (with L2 switch)
> 	  devices, say Y.
> 	  The network device supports dual 10M/100M Ethernet interfaces,
> 	  or one 10/100M Ethernet interface with two LAN ports.
> 	  To compile this driver as a module, choose M here.  The module
> 	  will be called sp_l2sw.
> 
> endif # NET_VENDOR_SUNPLUS
> 
> Best regards,
> Wells
> 


-- 
~Randy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ