1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00
linux/drivers/net/ethernet/intel/ixgbe
Przemek Kitszel aec806fb4a ixgbe: avoid sleeping allocation in ixgbe_ipsec_vf_add_sa()
Change kzalloc() flags used in ixgbe_ipsec_vf_add_sa() to GFP_ATOMIC, to
avoid sleeping in IRQ context.

Dan Carpenter, with the help of Smatch, has found following issue:
The patch eda0333ac2: "ixgbe: add VF IPsec management" from Aug 13,
2018 (linux-next), leads to the following Smatch static checker
warning: drivers/net/ethernet/intel/ixgbe/ixgbe_ipsec.c:917 ixgbe_ipsec_vf_add_sa()
	warn: sleeping in IRQ context

The call tree that Smatch is worried about is:
ixgbe_msix_other() <- IRQ handler
-> ixgbe_msg_task()
   -> ixgbe_rcv_msg_from_vf()
      -> ixgbe_ipsec_vf_add_sa()

Fixes: eda0333ac2 ("ixgbe: add VF IPsec management")
Reported-by: Dan Carpenter <dan.carpenter@linaro.org>
Link: https://lore.kernel.org/intel-wired-lan/db31a0b0-4d9f-4e6b-aed8-88266eb5665c@moroto.mountain
Reviewed-by: Michal Kubiak <michal.kubiak@intel.com>
Signed-off-by: Przemek Kitszel <przemyslaw.kitszel@intel.com>
Reviewed-by: Shannon Nelson <shannon.nelson@amd.com>
Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@intel.com> (A Contingent worker at Intel)
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
2024-03-25 09:57:21 -07:00
..
ixgbe.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_82598.c ixgbe: Rearrange args to fix reverse Christmas tree 2024-02-06 13:17:14 -08:00
ixgbe_82599.c ixgbe: Add 1000BASE-BX support 2024-03-04 20:49:58 -08:00
ixgbe_common.c ixgbe: Rearrange args to fix reverse Christmas tree 2024-02-06 13:17:14 -08:00
ixgbe_common.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb.c ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb_82598.c ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb_82598.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb_82599.c ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb_82599.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_dcb_nl.c intel: remove unused macros 2022-06-30 09:40:55 -07:00
ixgbe_debugfs.c netdev: pass the stuck queue to the timeout handler 2019-12-12 21:38:57 -08:00
ixgbe_ethtool.c ixgbe: Add 1000BASE-BX support 2024-03-04 20:49:58 -08:00
ixgbe_fcoe.c intel: legacy: field prep conversion 2023-12-18 11:15:53 -08:00
ixgbe_fcoe.h net: intel: Cleanup the copyright/license headers 2018-04-27 14:00:04 -04:00
ixgbe_ipsec.c ixgbe: avoid sleeping allocation in ixgbe_ipsec_vf_add_sa() 2024-03-25 09:57:21 -07:00
ixgbe_ipsec.h ixgbe: propagate XFRM offload state direction instead of flags 2022-05-06 08:32:52 +02:00
ixgbe_lib.c ixgbe: Fix panic during XDP_TX with > 64 CPUs 2023-04-27 11:54:33 +02:00
ixgbe_main.c Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue 2024-03-08 11:43:21 +00:00
ixgbe_mbx.c ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_mbx.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_model.h ixgbe: cleanup sparse warnings 2018-05-17 08:24:30 -07:00
ixgbe_phy.c ixgbe: Add 1000BASE-BX support 2024-03-04 20:49:58 -08:00
ixgbe_phy.h ixgbe: Add 1000BASE-BX support 2024-03-04 20:49:58 -08:00
ixgbe_ptp.c ixgbe: fix timestamp configuration code 2023-09-13 12:23:46 +01:00
ixgbe_sriov.c ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_sriov.h ixgbe: add the ability for the PF to disable VF link state 2022-03-08 07:41:18 -08:00
ixgbe_sysfs.c net: intel: Cleanup the copyright/license headers 2018-04-27 14:00:04 -04:00
ixgbe_txrx_common.h ixgbe: pull out stats update to common routines 2024-03-06 09:32:58 -08:00
ixgbe_type.h ixgbe: Add 1000BASE-BX support 2024-03-04 20:49:58 -08:00
ixgbe_x540.c ixgbe: Rearrange args to fix reverse Christmas tree 2024-02-06 13:17:14 -08:00
ixgbe_x540.h ixgbe: Convert ret val type from s32 to int 2024-02-06 13:17:14 -08:00
ixgbe_x550.c ixgbe: Clarify the values of the returning status 2024-02-06 13:17:14 -08:00
ixgbe_xsk.c ixgbe: pull out stats update to common routines 2024-03-06 09:32:58 -08:00
Makefile ixgbe/ixgbevf: fix XFRM_ALGO dependency 2018-10-31 10:53:15 -07:00