[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

arm: DomU Networking enable leads to Dom0 kernel oops


  • To: Stefano Stabellini <sstabellini@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>
  • From: Andrei Cherechesu <andrei.cherechesu@xxxxxxx>
  • Date: Fri, 24 Apr 2020 20:29:53 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=nxp.com; dmarc=pass action=none header.from=nxp.com; dkim=pass header.d=nxp.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Qm/PBDohmG5CFOQupDFGRlbnhPnzF9MU27NvNwOhObw=; b=mlakdOeFMhlAtl+xXX0fX0FTKeTBlfu6ifurXIyLr7+nOBkvFR1opcgzOmT6FP2W9laexneGg2lqn2WDaEsvRyeS2++3FH1mTmnLI74S3g1/xYo/wGbNZ7ZrYLl28IqLa52W7YQxlKad2ZYtgBcdKF3Q24egWo72sgfEk2BY59y5GGVXxNkhp1vX0exKzSD/lIhVFfQr+8lLUiWm033EWRyrlPNGRiZf8hU5si5XADbjjHviE8nqXDzj2lMbTWWx4v4GhAcvk8Trvrl0dTZ6Emm2yA/8cdzXdbZWFnCRSvg3Vt5RimXB0sD1+l/2iTQ8bRFZKIUC8T9PJAxMhDm+JQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Id7UHRY36KSui1J+eVFt712qXx642MwW+Iha4V3NISIJdDWPfbj8P2XKF9RBIbHsjH6H2oXiaanq1CM9z2MwIcrR8UTCC9G471O+4JH0AvU+F906tIQyvWLNtAMdlvgxHhhvUfrUSkaTPO0hZrjUITkFJ4FDH+13CgwmV02Hi2caVfGjhZtMiMugYKNHaIcTJA4r8kFi6Z0odt9924QQk/N7O4OPhuQN8H4IXArQiu3h5uDhPmr1wKzvE98k2agUhEXYykmsAcqnP2bitXWmUg1S5ex0a5JAZEWm7RpyhIUN5YjwGkNAsAqESF9UnfGEgEIWlAHuSnuS8WAuFhMGvg==
  • Authentication-results: spf=none (sender IP is ) smtp.mailfrom=andrei.cherechesu@xxxxxxx;
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • Delivery-date: Fri, 24 Apr 2020 20:30:09 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AdYaclAiZQv5zvC+SH+brmHp3N+n3w==
  • Thread-topic: arm: DomU Networking enable leads to Dom0 kernel oops

Hello,

 

Recently I’ve been trying to enable the networking in a conventional DomU (not dom0less).

The approach I used was the one described here: https://wiki.xen.org/wiki/Xen_Networking#Bridging.

 

But when I use xl to create DomU, I get a Kernel OOPS in Dom0. The setup is still responsive after this

and DomU boots successfully. However, if I try to enable `eth0` in DomU (using ip link dev set eth0 up),

I get a Kernel Panic in Dom0.

 

Here are the complete steps:

  1. Boot Dom0 and configure bridge:
    • brctl addbr xenbr0
    • brctl addif xenbr0 eth0
    • ip link set dev xenbr0 up
    • ip link set dev eth0 up
    • dhclient xenbr0

 

  1. ifconfig xenbr0 (ping 8.8.8.8 works):

xenbr0    Link encap:Ethernet  HWaddr B2:62:37:C9:BB:D7

          inet addr:192.168.0.185  Bcast:192.168.0.255  Mask:255.255.255.0

          inet6 addr: fe80::b062:37ff:fec9:bbd7/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:703 errors:0 dropped:0 overruns:0 frame:0

          TX packets:27 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:88213 (86.1 KiB)  TX bytes:3088 (3.0 KiB)

 

  1. ifconfig eth0:

eth0      Link encap:Ethernet  HWaddr B2:62:37:C9:BB:D7 

          inet6 addr: fe80::b062:37ff:fec9:bbd7/64 Scope:Link

          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1

          RX packets:1535 errors:0 dropped:2 overruns:0 frame:0

          TX packets:43 errors:0 dropped:0 overruns:0 carrier:0

          collisions:0 txqueuelen:1000

          RX bytes:450476 (439.9 KiB)  TX bytes:4248 (4.1 KiB)

          Interrupt:59 Base address:0xc000

 

  1. Add bridge to DomU config file:

vif = [ 'bridge=xenbr0' ]

 

  1. root@s32g274aevb-Dom0:~# xl create /etc/xen/domU1.cfg

After this I get the Kernel OOPS, because of a failed memory

access

[  413.367873] Unable to handle kernel paging request at virtual address 000006c000020070

In

               [  413.548189]  xenvif_rx_ring_slots_available+0x40/0xa0 [xen_netback]

              

The full log is attached at [0].

Using gdb, I found out that the access corresponds to the following source code lines:

               ==========

               (gdb)  l *xenvif_rx_ring_slots_available+0x40

0x65b0 is in xenvif_rx_ring_slots_available (/usr/src/kernel/include/linux/skbuff.h:4084).

4082      static inline bool skb_is_gso(const struct sk_buff *skb)

4083      {

4084                     return skb_shinfo(skb)->gso_size;

4085      }

                              ==========

 

  1. DomU boots, and then: root@s32g274aevb-DomU1:~# ip link set dev eth0 up

After this, I get a kernel panic in Dom0 because of another failed memory

access

               [ 5338.574809] Unable to handle kernel paging request at virtual address 000000c0ffff0028

in

               [ 5338.753128]  xenvif_tx_build_gops+0x528/0xef8 [xen_netback]

 

               The full log is attached at [1].

               Using gdb again, I found out the corresponding source code:

                              ==========

(gdb) l *xenvif_tx_build_gops+0x528

0xce8 is in xenvif_tx_build_gops (/usr/src/kernel/include/linux/skbuff.h:1272).

1269      #ifdef NET_SKBUFF_DATA_USES_OFFSET

1270      static inline unsigned char *skb_end_pointer(const struct sk_buff *skb)

1271      {

1272                     return skb->head + skb->end;

1273      }

                              ==========

 

Do you have any idea why this occurs? Have I misconfigured anything?

 

I’ve also tried to pass a static IP configuration for DomU in the config file,

and because it automatically enables eth0 at boot time, I no longer get the

oops, but a panic directly.

 

Thank you very much for your help,

Andrei Cherechesu,

NXP Semiconductors


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.