net: fealnx: fix build for UML
Subsystems (3)
PATCH 1/1 net: fealnx: fix build for UML
On i386, when builtin (not a loadable module), the fealnx driver inspects boot_cpu_data to see what CPU family it is running on, and then acts on that data. The "family" struct member (x86) does not exist when running on UML, so prevent that test and do the default action.
Prevents this build error on UML + i386:
../drivers/net/ethernet/fealnx.c: In function ‘netdev_open’:../drivers/net/ethernet/fealnx.c:861:19: error: ‘struct cpuinfo_um’ has no member named ‘x86’
--- drivers/net/ethernet/fealnx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/fealnx.c +1 -1
@@ -857,7 +857,7 @@ static int netdev_open(struct net_device np->bcrvalue |=0x04 ;/* big-endian */ #endif -#if defined(__i386__) && !defined(MODULE ) +#if defined(__i386__) && !defined(MODULE ) && !defined(CONFIG_UML )if (boot_cpu_data.x86 <=4 ) np->crvalue =0xa00 ;else
_______________________________________________
linux-um mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-um
This patch was applied to netdev/net-next.git (master) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net-next.git (master) by Jakub Kicinski <[email protected]>:
Quoted 8 lines · On Wed, 13 Oct 2021 22:05:00 -0700 you wrote:
On i386, when builtin (not a loadable module), the fealnx driver inspects
boot_cpu_datato see what CPU family it is running on, and then acts on that data. The "family" struct member (x86) does not exist when running on UML, so prevent that test and do the default action.Prevents this build error on UML + i386:
[...]
Here is the summary with links:
- [net-next] net: fealnx: fix build for UML
https://git.kernel.org/netdev/net-next/c/cd2621d07d51
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
_______________________________________________
linux-um mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-um