[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CYYPR11MB8429BE3AF9299834A36B53AABDC62@CYYPR11MB8429.namprd11.prod.outlook.com>
Date: Mon, 10 Jun 2024 09:53:51 +0000
From: "Pucha, HimasekharX Reddy" <himasekharx.reddy.pucha@...el.com>
To: Dawid Osuchowski <dawid.osuchowski@...ux.intel.com>,
"intel-wired-lan@...ts.osuosl.org" <intel-wired-lan@...ts.osuosl.org>
CC: "Kwan, Ngai-mint" <ngai-mint.kwan@...el.com>, "netdev@...r.kernel.org"
<netdev@...r.kernel.org>, "Chmielewski, Pawel" <pawel.chmielewski@...el.com>,
Simon Horman <horms@...nel.org>, "Polchlopek, Mateusz"
<mateusz.polchlopek@...el.com>
Subject: RE: [Intel-wired-lan] [PATCH iwl-net v5] ice: Do not get coalesce
settings while in reset
> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@...osl.org> On Behalf Of Dawid Osuchowski
> Sent: Friday, June 7, 2024 5:46 PM
> To: intel-wired-lan@...ts.osuosl.org
> Cc: Kwan, Ngai-mint <ngai-mint.kwan@...el.com>; netdev@...r.kernel.org; Chmielewski, Pawel <pawel.chmielewski@...el.com>; Simon Horman <horms@...nel.org>; Polchlopek, Mateusz <mateusz.polchlopek@...el.com>; Dawid Osuchowski <dawid.osuchowski@...ux.intel.com>
> Subject: [Intel-wired-lan] [PATCH iwl-net v5] ice: Do not get coalesce settings while in reset
>
> From: Ngai-Mint Kwan <ngai-mint.kwan@...el.com>
>
> Getting coalesce settings while reset is in progress can cause NULL pointer deference bug.
> If under reset, abort get coalesce for ethtool.
>
> We cannot use ice_wait_for_reset() since both the ethtool handler and the adapter reset flow call rtnl_lock() during operation. If we wait for reset completion inside of an ethtool handling function such as ice_get_coalesce(), the wait will always timeout due to reset being blocked by rtnl_lock() inside of ice_queue_set_napi() (which is called during reset process), and in turn we will always return -EBUSY anyways, with the added hang time of the timeout value.
>
> Fixes: 67fe64d78c43 ("ice: Implement getting and setting ethtool coalesce")
> Signed-off-by: Ngai-Mint Kwan <ngai-mint.kwan@...el.com>
> Reviewed-by: Mateusz Polchlopek <mateusz.polchlopek@...el.com>
> Signed-off-by: Pawel Chmielewski <pawel.chmielewski@...el.com>
> Reviewed-by: Simon Horman <horms@...nel.org>
> Signed-off-by: Dawid Osuchowski <dawid.osuchowski@...ux.intel.com>
> ---
> Changes since v1:
> * Added "Fixes:" tag
> Changes since v2:
> * Rebased over current IWL net branch
> * Confirmed that the issue previously reported for this patch [1] by Himasekhar Reddy Pucha was caused by other, internally tracked issue Changes since v3:
> * Using ice_wait_for_reset() instead of returning -EBUSY Changes since v4:
> * Rebased over current IWL net branch
> * Rollback the use of ice_wait_for_reset() due to rtnl_lock() deadlock issue described in [2] and commit msg
>
> [1] https://lore.kernel.org/netdev/BL0PR11MB3122D70ABDE6C2ACEE376073BD90A@BL0PR11MB3122.namprd11.prod.outlook.com/
> [2] https://lore.kernel.org/netdev/20240501195641.1e606747@kernel.org/T/#m1629ecfe88d26551852c5c97982cd10314991422
> ---
> drivers/net/ethernet/intel/ice/ice_ethtool.c | 3 +++
> 1 file changed, 3 insertions(+)
>
Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@...el.com> (A Contingent worker at Intel)
Powered by blists - more mailing lists