Message ID | 20231123124313.1398570-13-justinlai0215@realtek.com (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | Netdev Maintainers |
Headers | show |
Series | Add Realtek automotive PCIe driver | expand |
Hi Justin, kernel test robot noticed the following build warnings: [auto build test WARNING on net-next/main] url: https://github.com/intel-lab-lkp/linux/commits/Justin-Lai/rtase-Add-pci-table-supported-in-this-module/20231123-204759 base: net-next/main patch link: https://lore.kernel.org/r/20231123124313.1398570-13-justinlai0215%40realtek.com patch subject: [PATCH net-next v12 12/13] realtek: Update the Makefile and Kconfig in the realtek folder config: csky-randconfig-r081-20231124 (https://download.01.org/0day-ci/archive/20231124/202311241318.bdYlmH2b-lkp@intel.com/config) compiler: csky-linux-gcc (GCC) 13.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231124/202311241318.bdYlmH2b-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202311241318.bdYlmH2b-lkp@intel.com/ All warnings (new ones prefixed by >>): >> drivers/net/ethernet/realtek/rtase/rtase_main.c:2318:12: warning: 'rtase_resume' defined but not used [-Wunused-function] 2318 | static int rtase_resume(struct device *device) | ^~~~~~~~~~~~ >> drivers/net/ethernet/realtek/rtase/rtase_main.c:2305:12: warning: 'rtase_suspend' defined but not used [-Wunused-function] 2305 | static int rtase_suspend(struct device *device) | ^~~~~~~~~~~~~ vim +/rtase_resume +2318 drivers/net/ethernet/realtek/rtase/rtase_main.c 8f9d7c2677f7dc Justin Lai 2023-11-23 2304 da2f11aefe82ee Justin Lai 2023-11-23 @2305 static int rtase_suspend(struct device *device) da2f11aefe82ee Justin Lai 2023-11-23 2306 { da2f11aefe82ee Justin Lai 2023-11-23 2307 struct net_device *dev = dev_get_drvdata(device); da2f11aefe82ee Justin Lai 2023-11-23 2308 da2f11aefe82ee Justin Lai 2023-11-23 2309 if (netif_running(dev)) { da2f11aefe82ee Justin Lai 2023-11-23 2310 netif_stop_queue(dev); da2f11aefe82ee Justin Lai 2023-11-23 2311 netif_device_detach(dev); da2f11aefe82ee Justin Lai 2023-11-23 2312 rtase_hw_reset(dev); da2f11aefe82ee Justin Lai 2023-11-23 2313 } da2f11aefe82ee Justin Lai 2023-11-23 2314 da2f11aefe82ee Justin Lai 2023-11-23 2315 return 0; da2f11aefe82ee Justin Lai 2023-11-23 2316 } da2f11aefe82ee Justin Lai 2023-11-23 2317 da2f11aefe82ee Justin Lai 2023-11-23 @2318 static int rtase_resume(struct device *device) da2f11aefe82ee Justin Lai 2023-11-23 2319 { da2f11aefe82ee Justin Lai 2023-11-23 2320 struct net_device *dev = dev_get_drvdata(device); da2f11aefe82ee Justin Lai 2023-11-23 2321 struct rtase_private *tp = netdev_priv(dev); da2f11aefe82ee Justin Lai 2023-11-23 2322 int ret; da2f11aefe82ee Justin Lai 2023-11-23 2323 da2f11aefe82ee Justin Lai 2023-11-23 2324 /* restore last modified mac address */ da2f11aefe82ee Justin Lai 2023-11-23 2325 rtase_rar_set(tp, dev->dev_addr); da2f11aefe82ee Justin Lai 2023-11-23 2326 da2f11aefe82ee Justin Lai 2023-11-23 2327 if (!netif_running(dev)) da2f11aefe82ee Justin Lai 2023-11-23 2328 goto out; da2f11aefe82ee Justin Lai 2023-11-23 2329 da2f11aefe82ee Justin Lai 2023-11-23 2330 rtase_wait_for_quiescence(dev); da2f11aefe82ee Justin Lai 2023-11-23 2331 da2f11aefe82ee Justin Lai 2023-11-23 2332 rtase_tx_clear(tp); da2f11aefe82ee Justin Lai 2023-11-23 2333 rtase_rx_clear(tp); da2f11aefe82ee Justin Lai 2023-11-23 2334 da2f11aefe82ee Justin Lai 2023-11-23 2335 ret = rtase_init_ring(dev); da2f11aefe82ee Justin Lai 2023-11-23 2336 if (ret) { da2f11aefe82ee Justin Lai 2023-11-23 2337 netdev_err(dev, "unable to init ring\n"); da2f11aefe82ee Justin Lai 2023-11-23 2338 rtase_free_desc(tp); da2f11aefe82ee Justin Lai 2023-11-23 2339 return -ENOMEM; da2f11aefe82ee Justin Lai 2023-11-23 2340 } da2f11aefe82ee Justin Lai 2023-11-23 2341 da2f11aefe82ee Justin Lai 2023-11-23 2342 rtase_hw_config(dev); da2f11aefe82ee Justin Lai 2023-11-23 2343 /* always link, so start to transmit & receive */ da2f11aefe82ee Justin Lai 2023-11-23 2344 rtase_hw_start(dev); da2f11aefe82ee Justin Lai 2023-11-23 2345 da2f11aefe82ee Justin Lai 2023-11-23 2346 netif_wake_queue(dev); da2f11aefe82ee Justin Lai 2023-11-23 2347 netif_device_attach(dev); da2f11aefe82ee Justin Lai 2023-11-23 2348 out: da2f11aefe82ee Justin Lai 2023-11-23 2349 da2f11aefe82ee Justin Lai 2023-11-23 2350 return 0; da2f11aefe82ee Justin Lai 2023-11-23 2351 } da2f11aefe82ee Justin Lai 2023-11-23 2352
diff --git a/drivers/net/ethernet/realtek/Kconfig b/drivers/net/ethernet/realtek/Kconfig index 93d9df55b361..57ef924deebd 100644 --- a/drivers/net/ethernet/realtek/Kconfig +++ b/drivers/net/ethernet/realtek/Kconfig @@ -113,4 +113,21 @@ config R8169 To compile this driver as a module, choose M here: the module will be called r8169. This is recommended. +config RTASE + tristate "Realtek Automotive Switch 9054/9068/9072/9075/9068/9071 PCIe Interface support" + depends on PCI + select CRC32 + help + Say Y here if you have a Realtek Ethernet adapter belonging to + the following families: + RTL9054 5GBit Ethernet + RTL9068 5GBit Ethernet + RTL9072 5GBit Ethernet + RTL9075 5GBit Ethernet + RTL9068 5GBit Ethernet + RTL9071 5GBit Ethernet + + To compile this driver as a module, choose M here: the module + will be called rtase. This is recommended. + endif # NET_VENDOR_REALTEK diff --git a/drivers/net/ethernet/realtek/Makefile b/drivers/net/ethernet/realtek/Makefile index 2e1d78b106b0..0c1c16f63e9a 100644 --- a/drivers/net/ethernet/realtek/Makefile +++ b/drivers/net/ethernet/realtek/Makefile @@ -8,3 +8,4 @@ obj-$(CONFIG_8139TOO) += 8139too.o obj-$(CONFIG_ATP) += atp.o r8169-objs += r8169_main.o r8169_firmware.o r8169_phy_config.o obj-$(CONFIG_R8169) += r8169.o +obj-$(CONFIG_RTASE) += rtase/
1. Add the RTASE entry in the Kconfig. 2. Add the CONFIG_RTASE entry in the Makefile. Signed-off-by: Justin Lai <justinlai0215@realtek.com> --- drivers/net/ethernet/realtek/Kconfig | 17 +++++++++++++++++ drivers/net/ethernet/realtek/Makefile | 1 + 2 files changed, 18 insertions(+)