Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1571774

Re: [PATCH] net: ethernet: ti: cpsw: fix NULL pointer dereference in switch mode

From David Miller <davem@davemloft.net>
Newsgroups linux.kernel
Subject Re: [PATCH] net: ethernet: ti: cpsw: fix NULL pointer dereference in switch mode
Date 2017-02-01 18:10 +0100
Message-ID <t66zV-fo-37@gated-at.bofh.it> (permalink)
References <t5MUx-51K-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Grygorii Strashko <grygorii.strashko@ti.com>
Date: Tue, 31 Jan 2017 14:04:04 -0600

> In switch mode on struct cpsw_slave->ndev field will be initialized with
> proper value only for the one cpsw slave port, as result
> cpsw_get_usage_count() will generate "Unable to handle kernel NULL pointer
> dereference" exception when first ethernet interface is opening
> cpsw_ndo_open(). This issue causes boot regression on AM335x EVM and
> reproducible on am57xx-evm (switch mode).
> Fix it by adding additional check for !cpsw->slaves[i].ndev in
> cpsw_get_usage_count().
> 
> Cc: Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org>
> fixes: 03fd01ad0eea ("net: ethernet: ti: cpsw: don't duplicate ndev_running")

Please capitalize "Fixes: " in the future.

> Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>

Applied, thanks.

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH] net: ethernet: ti: cpsw: fix  NULL pointer dereference in switch mode Grygorii Strashko <grygorii.strashko@ti.com> - 2017-01-31 21:10 +0100
  Re: [PATCH] net: ethernet: ti: cpsw: fix  NULL pointer dereference  in switch mode Ivan Khoronzhuk <ivan.khoronzhuk@linaro.org> - 2017-02-01 17:40 +0100
  Re: [PATCH] net: ethernet: ti: cpsw: fix NULL pointer dereference  in switch mode David Miller <davem@davemloft.net> - 2017-02-01 18:10 +0100

csiph-web