[PATCH] net/bnxt: fix null pointer dereference in bnxt_hwrm_port_led_cfg()

2022-08-11 Thread Mao YingMing
From: maoyingming VFs's "bp->leds" is allways null, check bp->leds is not null before use bp->leds->num_leds. segfault backtrace in trex program when use VF: 11: bnxt_hwrm_port_led_cfg (bp=0x23ffb2140, led_on=true) 10: bnxt_dev_led_on_op (dev=0x22d7780 ) 9: rte_eth_led_on (port_id=0) 8: DpdkTR

[PATCH] net/bnxt: fix null pointer dereference in bnxt_hwrm_port_led_cfg()

2022-08-11 Thread Mao YingMing
From: maoyingming VFs's "bp->leds" is allways null, check bp->leds is not null before use bp->leds->num_leds. segfault backtrace in trex program when use VF: 11: bnxt_hwrm_port_led_cfg (bp=0x23ffb2140, led_on=true) 10: bnxt_dev_led_on_op (dev=0x22d7780 ) 9: rte_eth_led_on (port_id=0) 8: DpdkTR

[PATCH] net/bnxt: fix null pointer dereference in bnxt_hwrm_port_led_cfg()

2022-08-11 Thread Mao YingMing
From: maoyingming VFs's "bp->leds" is allways null, check bp->leds is not null before use bp->leds->num_leds. segfault backtrace in trex program when use VF: 11: bnxt_hwrm_port_led_cfg (bp=0x23ffb2140, led_on=true) 10: bnxt_dev_led_on_op (dev=0x22d7780 ) 9: rte_eth_led_on (port_id=0) 8: DpdkTR

[PATCH] net/bnxt: fix null pointer dereference in bnxt_hwrm_port_led_cfg()

2022-08-01 Thread Mao YingMing
From: maoyingming VFs's "bp->leds" is allways null, check bp->leds is not null before use bp->leds->num_leds. segfault backtrace in trex program when use VF: 11: bnxt_hwrm_port_led_cfg (bp=0x23ffb2140, led_on=true) 10: bnxt_dev_led_on_op (dev=0x22d7780 ) 9: rte_eth_led_on (port_id=0) 8: DpdkTR

Re: [PATCH] net/bnxt: fix null pointer dereference in bnxt_hwrm_port_led_cfg()

2022-08-01 Thread Somnath Kotur
On Tue, Aug 2, 2022 at 8:33 AM Mao YingMing wrote: > Thanks for the patch > From: maoyingming > > VFs's "bp->leds" is allways null, check bp->leds is > not null before use bp->leds->num_leds. Typo in 'always' You can just say ' For VFs , bp->leds is uninitialized' > > segfault backtrace in trex p