linux/drivers
Théo Lebrun ec518a7c4b net: macb: drop CONFIG_OF #if block
Fix -Wimplicit-function-declaration error on CONFIG_OF=n builds:

   drivers/net/ethernet/cadence/macb_main.c: In function ‘macb_probe’:
   drivers/net/ethernet/cadence/macb_main.c:5951:15: error: implicit
   declaration of function ‘macb_alloc_tieoff’ [...]
    5951 |         err = macb_alloc_tieoff(bp);
         |               ^~~~~~~~~~~~~~~~~
   drivers/net/ethernet/cadence/macb_main.c:5973:9: error: implicit
   declaration of function ‘macb_free_tieoff’ [...]
    5973 |         macb_free_tieoff(bp);
         |         ^~~~~~~~~~~~~~~~

Error got introduced because functions are mistakenly declared in a
`#if defined(CONFIG_OF)` block. Instead of moving functions around,
avoid any future mistake and drop the block entirely.

Change the module content slightly on CONFIG_OF=n. Previously match
tables were ignored. Now they appear in the resulting build. This is
considered trivial in size by most and is the common case:

   ⟩ 18 out of 254 OF net drivers reference CONFIG_OF
   ⟩ rg -lF 'MODULE_DEVICE_TABLE(of,' drivers/net/ | tee /tmp/a | wc -l
   254
   ⟩ xargs -a /tmp/a rg -l CONFIG_OF | wc -l
   18

Tangent: no, of_match_ptr() does not imply that the compiler can
optimize out match tables, because MODULE_DEVICE_TABLE(of, ...)
unconditionally puts the match tables in the binary. It is only meant
to avoid undefined declaration issues when match tables are hidden
behind a #ifdef, as was done before. We therefore drop the macro call.

Fixes: 5262eab946 ("net: macb: allocate tieoff descriptor once across device lifetime")
Reported-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Théo Lebrun <theo.lebrun@bootlin.com>
Reviewed-by: Nicolai Buchwitz <nb@tipi-net.de>
Acked-by: Conor Dooley <conor.dooley@microchip.com>
Link: https://patch.msgid.link/20260820-macb-fix-x86-v1-1-b2e7c902104e@bootlin.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2026-08-20 12:13:32 -07:00
..
accel accel/amdxdna: Skip unmapped range in aie2_populate_range() 2026-08-12 23:12:20 -07:00
accessibility
acpi Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
amba
android Rust changes for v7.3 2026-08-18 11:25:09 -07:00
ata ata changes for 7.3 2026-08-19 12:31:50 -07:00
atm atm: remove unused ATM PHY operations 2026-06-16 08:53:53 -07:00
auxdisplay Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
base Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
bcma
block Rust changes for v7.3 2026-08-18 11:25:09 -07:00
bluetooth Bluetooth: btmtksdio: fix usage_count leak when autosuspend_delay is negative 2026-08-07 15:40:27 -04:00
bus FSL SOC Changes for 7.3 2026-08-10 10:15:56 +02:00
cache Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
cdrom cdrom: fix stack out-of-bounds read in CDROMVOLCTRL 2026-07-20 21:54:52 -06:00
cdx Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
char This update includes the following changes: 2026-08-19 17:25:42 -07:00
clk pmdomain providers: 2026-08-19 09:28:46 -07:00
clocksource VDSO updates: 2026-08-18 16:56:25 -07:00
comedi comedi: comedi_parport: deal with premature interrupt 2026-07-17 14:50:35 +02:00
connector
counter Counter fixes for 7.2 2026-08-06 11:03:41 +02:00
cpufreq Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
cpuidle soc: qcom: Avoid SCM and SPM for cpuidle drivers 2026-07-11 10:01:51 -05:00
crypto This update includes the following changes: 2026-08-19 17:25:42 -07:00
cxl cxl: Support dpa without a mailbox 2026-06-29 10:55:47 -07:00
dax mm.git review status for mm-hotfixes-stable..mm-stable 2026-06-19 10:14:34 -07:00
dca
devfreq Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
dibs net/dibs: Correct freeing of dmb_clientid_arr 2026-08-12 17:08:05 -07:00
dio
dma dmaengine fixes for v7.2 2026-08-02 09:19:40 -07:00
dma-buf udmabuf: Ensure to perform cache synchronisation in begin_cpu_udmabuf() 2026-07-10 16:26:39 -07:00
dpll Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-08-18 10:42:41 -07:00
edac x86/msr updates for v7.3: 2026-08-18 14:02:15 -07:00
eisa
extcon Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
firewire - Get rid of static_cpu_has() - one less API to care about testing CPU 2026-08-18 19:09:42 -07:00
firmware sound updates for 7.3-rc1 2026-08-19 10:04:59 -07:00
fpga Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
fsi Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
fwctl rust: introduce abstractions for fwctl 2026-08-14 19:21:17 -03:00
gnss
gpib gpio: legacy interface cleanups for 7.3 2026-07-27 09:56:49 +02:00
gpio gpio updates for v7.3-rc1 2026-08-19 09:10:07 -07:00
gpu This update includes the following changes: 2026-08-19 17:25:42 -07:00
greybus
hid Major changes: 2026-08-20 07:36:20 -07:00
hsi Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
hte Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
hv mshv_vtl: bounds-check cpu index in vtl mmap fault handler 2026-07-31 20:02:04 +00:00
hwmon hwmon updates for v7.3 2026-08-19 09:56:28 -07:00
hwspinlock hwspinlock: qcom: avoid uninitialized struct members 2026-06-08 21:51:12 -05:00
hwtracing intel_th: fix MSC output device reference leak 2026-07-17 14:52:08 +02:00
i2c Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
i3c i3c: mipi-i3c-hci: Use named initializers for platform_device_id's .driver_data 2026-06-16 23:19:45 +02:00
idle Merge branch 'intel-idle-lpi' 2026-08-07 21:22:50 +02:00
iio Linux 7.2 2026-08-18 14:21:04 +02:00
infiniband Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-07-23 14:07:40 -07:00
input hid-for-linus-2026081901 2026-08-19 10:00:31 -07:00
interconnect Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
iommu iommufd v7.3 merge window pull request 2026-08-19 12:42:58 -07:00
ipack
irqchip Interrupt chip driver updates: 2026-08-18 15:24:18 -07:00
leds Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
macintosh sched/cputime: Remove superfluous and error prone kcpustat_field() parameter 2026-06-02 21:27:25 +02:00
mailbox Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
mcb
md - 6 minor cleanups found by Claude Opus 4.6 2026-08-19 12:35:15 -07:00
media [GIT PULL for v7.3] media updates 2026-08-19 10:09:22 -07:00
memory Memory controller drivers for v7.3 2026-07-29 16:56:11 +02:00
memstick memstick: ms_block: reject a card that reports too many blocks 2026-07-06 17:09:30 +02:00
message
mfd Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
misc mei: pull kvfree out of spinlock 2026-07-31 13:28:05 +02:00
mmc Networking changes for 7.3. 2026-08-20 08:16:04 -07:00
most
mtd Among the most important fixes that we have here, there are: 2026-07-17 09:30:17 -07:00
mux Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
net net: macb: drop CONFIG_OF #if block 2026-08-20 12:13:32 -07:00
nfc Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-08-18 10:42:41 -07:00
ntb NTB updates include an EPF bug fix to prevent an invalid unmap during 2026-06-28 07:46:12 -07:00
nubus
nvdimm Updates for the 7.2 release 2026-06-18 16:27:58 -07:00
nvme block-7.2-20260625 2026-06-25 09:56:47 -07:00
nvmem nvmem: layouts: Add fixed-layout driver 2026-07-31 11:00:13 +02:00
of Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
opp opp: Use clk_get_optional() to avoid leaving opp_table->clk as an error pointer 2026-08-06 11:54:14 +05:30
parisc
parport
pci Networking changes for 7.3. 2026-08-20 08:16:04 -07:00
pcmcia pcmcia: replace linux/gpio.h inclusions 2026-07-24 20:12:48 +02:00
peci
perf perf: arm_pmuv3: Zero initialize hw_id branch stack field 2026-08-07 11:55:16 +00:00
phy gpio updates for v7.3-rc1 2026-08-19 09:10:07 -07:00
pinctrl Linux 7.2 2026-08-18 14:21:04 +02:00
platform Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
pmdomain Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
pnp Merge branches 'acpi-numa', 'acpi-misc' and 'pnp' 2026-08-07 20:01:31 +02:00
power power sequencing updates for v7.3-rc1 2026-08-19 09:08:06 -07:00
powercap x86/msr updates for v7.3: 2026-08-18 14:02:15 -07:00
pps Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
ps3
ptp Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-08-18 10:42:41 -07:00
pwm Driver core changes for 7.3-rc1 2026-08-19 10:42:18 -07:00
rapidio mm.git review status for mm-hotfixes-stable..mm-nonmm-stable 2026-06-21 13:20:19 -07:00
ras x86/ras: Move contents from arch/x86/ras/Kconfig into drivers/ras/Kconfig 2026-07-01 18:40:09 -07:00
regulator regulator: Updates for v7.3 2026-08-19 09:36:58 -07:00
remoteproc remoteproc: qcom: pas: Drop start/stop completion from struct qcom_pas 2026-06-08 21:53:51 -05:00
resctrl arm64 updates for 7.3 2026-08-18 11:57:17 -07:00
reset Linux 7.2-rc7 2026-08-10 01:20:05 +02:00
rpmsg rpmsg update for v7.2 2026-06-20 23:31:15 -07:00
rtc Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
s390 Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2026-08-13 11:00:14 -07:00
sbus
scsi ata changes for 7.3 2026-08-19 12:31:50 -07:00
sh
siox Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
slimbus slimbus: qcom-ngd-ctrl: use platform_device_set_of_node() 2026-07-10 16:07:09 +02:00
soc spi: Updates for v7.3 2026-08-19 09:47:41 -07:00
soundwire soundwire: bus_type: Create IRQ mapping before calling driver probe() 2026-08-14 13:53:25 +01:00
spi spi: Updates for v7.3 2026-08-19 09:47:41 -07:00
spmi Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
ssb
staging Networking changes for 7.3. 2026-08-20 08:16:04 -07:00
target vfs-7.3-rc1.kthread 2026-08-17 11:35:12 -07:00
tc
tee soc: drivers for 7.3 2026-08-18 19:40:29 -07:00
thermal - Get rid of static_cpu_has() - one less API to care about testing CPU 2026-08-18 19:09:42 -07:00
thunderbolt thunderbolt: Initialize ->domain_released completion before it is being used 2026-07-30 06:47:32 +02:00
tty Linux 7.2-rc7 2026-08-10 01:20:05 +02:00
ufs scsi: core: pair EH runtime PM get and put 2026-08-07 11:00:49 -04:00
uio uio_hv_generic: Bind to FCopy device by default 2026-07-17 14:50:09 +02:00
usb Networking changes for 7.3. 2026-08-20 08:16:04 -07:00
vdpa vdpa/mlx5: Fix buffer length in create_direct_keys() 2026-08-03 15:21:54 -04:00
vfio vfio: Enable cdev noiommu mode under iommufd 2026-07-14 12:05:01 -03:00
vhost vhost-net: wake queue of tun/tap after ptr_ring consume 2026-08-07 17:29:15 -07:00
video fbdev: bitblit: bound-check glyph index in bit_cursor() 2026-08-08 08:08:58 +02:00
virt arm64 updates for 7.3 2026-08-18 11:57:17 -07:00
virtio mm: page_reporting: allow driver to set batch capacity 2026-07-09 15:48:56 -07:00
w1 Replace <linux/mod_devicetable.h> by more specific <linux/device-id/*.h> (c files) 2026-07-03 07:38:17 +02:00
watchdog watchdog updates for v7.3 2026-08-19 09:53:35 -07:00
xen xenbus: Unregister reboot notifier on init failure 2026-08-13 12:48:57 +02:00
zorro
Kconfig
Makefile