[dpdk-dev] [PATCH v2] igb_uio: remove device reset in release

Wu, Jingjing jingjing.wu at intel.com
Wed Nov 8 06:23:50 CET 2017



> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas at monjalon.net]
> Sent: Wednesday, November 8, 2017 7:57 AM
> To: Yigit, Ferruh <ferruh.yigit at intel.com>
> Cc: dev at dpdk.org; stable at dpdk.org; Tan, Jianfeng <jianfeng.tan at intel.com>;
> Wu, Jingjing <jingjing.wu at intel.com>; Shijith Thotton
> <shijith.thotton at caviumnetworks.com>; Gregory Etelson <gregory at weka.io>;
> Harish Patil <harish.patil at cavium.com>; George Prekas
> <george.prekas at epfl.ch>; Gonzalez Monroy, Sergio
> <sergio.gonzalez.monroy at intel.com>; Rasesh Mody
> <rasesh.mody at cavium.com>; Lee Roberts <lee.roberts at hpe.com>; Stephen
> Hemminger <stephen at networkplumber.org>; Chas Williams <chas3 at att.com>
> Subject: Re: [dpdk-dev] [PATCH v2] igb_uio: remove device reset in release
> 
> 07/11/2017 23:29, Ferruh Yigit:
> > More error reported for device reset in release() [1], when device
> > pass-through to the guest, host kernel crash on guest exit.
> >
> > Removing the reset completely.
> >
> > This is close to reverting commit b58eedfc7dd5 [2], taking into
> > account previous fix to remove reset in open as well [3], but not exactly same.
> >
> > With latest code, interrupts are enabled in uio open() callback and
> > disabled in uio release() callback, so when a DPDK application exit
> > device interrupts are disabled. Previously interrupts were only
> > enabled once in igb_uio module insert and disabled in module removal.
> >
> > Also with latest code device set as bus master in open() and master
> > cleared in release(), clearing bus master should prevent further DMA
> > which was one of the target of the initial patch.
> >
> > The initial intention was also to reset the device to be sure it has
> > been left in proper state, but currently that part is missing because
> > of reported problem(s).
> >
> > Still igb_uio should be safer comparing to the pre b58eedfc7dd5 state.
> >
> > [1]
> > http://dpdk.org/ml/archives/dev/2017-November/081459.html
> >
> > [2]
> > b58eedfc7dd5 ("igb_uio: issue FLR during open and release of device
> > file")
> >
> > [3]
> > f73b38e9245d ("igb_uio: remove device reset in open")
> >
> > Fixes: e3a64deae2d5 ("igb_uio: prevent reset for bnx2x devices")
> > Fixes: b58eedfc7dd5 ("igb_uio: issue FLR during open and release of
> > device file")
> > Cc: stable at dpdk.org
> >
> > Signed-off-by: Ferruh Yigit <ferruh.yigit at intel.com>
> 
> We can say you tried hard to make igb_uio cleaner and safer :)
> 
That's true! Thanks a lot, Ferruh!!

> Applied, thanks for the detailed explanations.



More information about the dev mailing list