can't compile 3.10.107 kernel for C1+

Moderators: mdrjr, odroid

can't compile 3.10.107 kernel for C1+

Unread postby sputnik » Wed Sep 13, 2017 12:26 pm

Am I the only one? Actually I can compile it by commenting out 1 line. But 1st, the details. I get this:
Code: Select all
drivers/amlogic/ethernet/am_net8218.c:1474:2: error: unknown field ‘ndo_poll_controller’ specified in initializer
  .ndo_poll_controller = fake_netpoll,
  ^
drivers/amlogic/ethernet/am_net8218.c:1474:25: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
  .ndo_poll_controller = fake_netpoll,
                         ^
drivers/amlogic/ethernet/am_net8218.c:1474:25: note: (near initialization for ‘am_netdev_ops.ndo_do_ioctl’)
distcc[3108] ERROR: compile drivers/amlogic/ethernet/am_net8218.c on localhost failed
scripts/Makefile.build:308: recipe for target 'drivers/amlogic/ethernet/am_net8218.o' failed
make[3]: *** [drivers/amlogic/ethernet/am_net8218.o] Error 1
scripts/Makefile.build:455: recipe for target 'drivers/amlogic/ethernet' failed
make[2]: *** [drivers/amlogic/ethernet] Error 2
scripts/Makefile.build:455: recipe for target 'drivers/amlogic' failed
make[1]: *** [drivers/amlogic] Error 2
Makefile:803: recipe for target 'drivers' failed
make: *** [drivers] Error 2
make: *** Waiting for unfinished jobs....
Similar to what mad_ady reports here on the XU-(3?4): https://forum.odroid.com/viewtopic.php?f=146&t=27579#p195591
It compiles ok if I do this:
Code: Select all
--- am_net8218.c   2017-09-12 20:15:20.061074560 -0700
+++ am_net8218.c.my   2017-09-12 20:16:30.601600953 -0700
@@ -1470,7 +1470,8 @@
    .ndo_change_mtu         = eth_change_mtu,
    .ndo_set_mac_address    = set_mac_addr_n,
    .ndo_validate_addr      = eth_validate_addr,
-   .ndo_poll_controller   = fake_netpoll,
+   /* let's comment out the next line:
+   .ndo_poll_controller   = fake_netpoll, */
 };
 
 static int aml_ethtool_get_settings(struct net_device *dev,
Which I believe will be ok for me because I don't plan to use netconsole on this device, although I'd like the option, I use netconsole on other devices here. But I'm puzzled because the Ubuntu image is apparently available and no one else has commented on it. Lost...
sputnik
 
Posts: 63
Joined: Tue Aug 11, 2015 9:39 am
languages_spoken: english, some spanish
ODROIDs: C1+

Re: can't compile 3.10.107 kernel for C1+

Unread postby mad_ady » Wed Sep 13, 2017 2:33 pm

Hmm, strange. I'll try to compile it again and see. Most likely you are treating warnings as errors. Which guide are you using to compile it?
User avatar
mad_ady
 
Posts: 2743
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2

Re: can't compile 3.10.107 kernel for C1+

Unread postby sputnik » Wed Sep 13, 2017 2:56 pm

No guides, same way I compile all my kernels, it fails at the make stage. Same basic .config I had with 3.10.104 kernel.
sputnik
 
Posts: 63
Joined: Tue Aug 11, 2015 9:39 am
languages_spoken: english, some spanish
ODROIDs: C1+

Re: can't compile 3.10.107 kernel for C1+

Unread postby sputnik » Wed Sep 13, 2017 8:28 pm

OK, got it by following the breadcrumbs on the changes on the r8152 driver. Daviessm's comment toward the end pointed me in the right direction https://github.com/hardkernel/linux/commit/de1a48357a7b9cff8ba07176fc9b8aac632f8ff6. I also had all of the net_poll and netconsole items unset, edited my .config directly ( like you're not supposed to do) and now it looks like all good. So it seems the issue is should those items being unset cause the compile to fail? It doesn't seem right to me, but I confess I don't know for sure. Since I have a custom config that works here I just briefly look at the diff between it and the defconfig. And of course I always do a make silentoldconfig to catch anything new in there.
Last edited by sputnik on Wed Sep 13, 2017 8:34 pm, edited 1 time in total.
sputnik
 
Posts: 63
Joined: Tue Aug 11, 2015 9:39 am
languages_spoken: english, some spanish
ODROIDs: C1+

Re: can't compile 3.10.107 kernel for C1+

Unread postby mad_ady » Wed Sep 13, 2017 8:32 pm

Thanks for pointing that out! I'll add if defs around the structure so that it builds without problem if NETCONSOLE is not enabled and send it to mdrjr as a PR. I hope I get around to doing it next week.
User avatar
mad_ady
 
Posts: 2743
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2


Return to Issues

Who is online

Users browsing this forum: No registered users and 2 guests