Netdev List
 help / color / mirror / Atom feed
* [PATCH net 0/2] net: dsa: two small bug fixes
From: Florian Fainelli @ 2014-12-11 20:49 UTC (permalink / raw)
  To: netdev; +Cc: davem, computersforpeace, andrey.volkov, Florian Fainelli

Hi David,

Here are two small fixes for the DSA slave interface creation code:

- first patch fixes a null pointer de-reference with an invalid PHY
  device pointer while calling phy_connect_direct()

- second path propagates the dsa_slave_phy_setup() error code down to
  its caller: dsa_slave_create

Thanks!

Florian Fainelli (2):
  net: dsa: handle non-existing PHYs on switch internal bus
  net: dsa: propagate error code from dsa_slave_phy_setup

 net/dsa/slave.c | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)

-- 
2.1.0

^ permalink raw reply

* Re: [PATCH net-next RESEND] net: Do not call ndo_dflt_fdb_dump if ndo_fdb_dump is defined.
From: Jamal Hadi Salim @ 2014-12-11 20:40 UTC (permalink / raw)
  To: Roopa Prabhu, Hubert Sokolowski; +Cc: netdev, Vlad Yasevich
In-Reply-To: <5489D53E.5010603@cumulusnetworks.com>

On 12/11/14 12:32, Roopa Prabhu wrote:

>>
> Thanks. yes, that is a problem. And, this mac0 is not a bridge port
> correct ?.
>

Aha. I think this is the key. It is NOT a bridge port. This is why i
was explicit to ask for the commit log tests to be run.

> But, for the same test case, when mac0 is a bridge port, does your patch
> under review make both the entries go away for a bridge port ?.
> (If i understand jamal correctly, this is his concern).

I am interested to see the answer.
More importantly I am hoping Vlad would wake up and say something.

cheers,
jamal

^ permalink raw reply

* Re: [PATCH v7 0/4] arch: Add lightweight memory barriers for coherent memory access
From: David Miller @ 2014-12-11 20:32 UTC (permalink / raw)
  To: alexander.duyck
  Cc: alexander.h.duyck, linux-arch, netdev, linux-kernel, arnd,
	mathieu.desnoyers, peterz, benh, heiko.carstens, mingo, mikey,
	linux, donald.c.skidmore, matthew.vick, geert, jeffrey.t.kirsher,
	romieu, paulmck, nic_swsd, will.deacon, michael, tony.luck,
	torvalds, oleg, schwidefsky, fweisbec
In-Reply-To: <54892B87.3020909@gmail.com>

From: Alexander Duyck <alexander.duyck@gmail.com>
Date: Wed, 10 Dec 2014 21:28:39 -0800

> It occurs to me that I never got a sign off from any of the maintainers
> on getting this pulled in.
> 
> Since the merge window is open I was wondering which tree I should make
> sure these patches apply to and who will be the one to pull them in?
> Since I was modifying network drivers should I resubmit them for netdev,
> or should I submit them for asm-generic or some other tree?

I have no problem taking this via my tree, but I want to see agreement
from other interested parties.

^ permalink raw reply

* Re: [PATCH net v9 0/7] cxgb4/cxgbi: misc. fixes for cxgb4i
From: David Miller @ 2014-12-11 20:28 UTC (permalink / raw)
  To: anish; +Cc: kxie, linux-scsi, netdev, hariprasad, hch, James.Bottomley,
	michaelc
In-Reply-To: <525DB349B3FB5444AE057A887CB2A8D8D9AA8E@nice.asicdesigners.com>

From: Anish Bhatt <anish@chelsio.com>
Date: Thu, 11 Dec 2014 20:24:48 +0000

>> This series does not apply cleanly at all to net-next, it gets many
>> rejects.
> 
> Hey Dave, this patchset was mostly bugfixes and hence meant for net where it
> applies cleanly. not net-next. We can rebase to net-next and send if you're still
>  willing to take it before net-next closes.

You absolutely must rebase it on net-next.

^ permalink raw reply

* Re: Bug: mv643xxx fails with highmem
From: David Miller @ 2014-12-11 20:27 UTC (permalink / raw)
  To: linux; +Cc: B38611, fabio.estevam, ezequiel.garcia, netdev
In-Reply-To: <20141211202507.GS11285@n2100.arm.linux.org.uk>

From: Russell King - ARM Linux <linux@arm.linux.org.uk>
Date: Thu, 11 Dec 2014 20:25:07 +0000

> Would other drivers need fixing for this as well?  Eg, fec_main.c
> does the following, and this driver is used on iMX6 which can also have
> highmem:
> 
> static int
> fec_enet_txq_submit_frag_skb(struct fec_enet_priv_tx_q *txq,
>                              struct sk_buff *skb,
>                              struct net_device *ndev)
> {
>                 bufaddr = page_address(this_frag->page.p) + this_frag->page_offset;
> ...
>                 addr = dma_map_single(&fep->pdev->dev, bufaddr, frag_len,
>                                       DMA_TO_DEVICE);

Probably, yes.

^ permalink raw reply

* Re: Bug: mv643xxx fails with highmem
From: Ezequiel Garcia @ 2014-12-11 20:25 UTC (permalink / raw)
  To: Russell King - ARM Linux, David Miller, Nimrod Andy,
	Fabio Estevam
  Cc: netdev, Thomas Petazzoni, Gregory CLEMENT
In-Reply-To: <20141211202507.GS11285@n2100.arm.linux.org.uk>

On 12/11/2014 05:25 PM, Russell King - ARM Linux wrote:
> On Thu, Dec 11, 2014 at 03:10:55PM -0500, David Miller wrote:
>> From: Russell King - ARM Linux <linux@arm.linux.org.uk>
>> Date: Thu, 11 Dec 2014 19:49:20 +0000
>>
>>> Commit 69ad0dd7af22 removed skb_frag_dma_map() in favour of mapping
>>> all fragments with dma_map_single().  This fails when the driver is
>>> used in an environment with highmem.
>>
>> This change looks really buggy to me.
>>
>> Unfortunately, all the changes he subsequently makes for software TSO
>> support depend upon this :-/
>>
>> The change is definitely wrong.
> 
> Thanks for confirming where the bug is.
> 
> Would other drivers need fixing for this as well?  Eg, fec_main.c
> does the following, and this driver is used on iMX6 which can also have
> highmem:
> 
> static int
> fec_enet_txq_submit_frag_skb(struct fec_enet_priv_tx_q *txq,
>                              struct sk_buff *skb,
>                              struct net_device *ndev)
> {
>                 bufaddr = page_address(this_frag->page.p) + this_frag->page_offset;
> ...
>                 addr = dma_map_single(&fep->pdev->dev, bufaddr, frag_len,
>                                       DMA_TO_DEVICE);
> 

And mvneta seems to have that pattern too: see mvneta_tx_frag_process().
-- 
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com

^ permalink raw reply

* Re: bind() should not return -EADDRINUSE
From: David Miller @ 2014-12-11 20:25 UTC (permalink / raw)
  To: psusi; +Cc: netdev
In-Reply-To: <5489FD51.3030609@ubuntu.com>

From: Phillip Susi <psusi@ubuntu.com>
Date: Thu, 11 Dec 2014 15:23:45 -0500

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 12/11/2014 3:18 PM, David Miller wrote:
>> From: Phillip Susi <psusi@ubuntu.com> Date: Thu, 11 Dec 2014
>> 15:17:12 -0500
>> 
>>> Says who?
>> 
>> Says multiple decades of precendence.
> 
> "It has always been broken, so it should stay broken" isn't a very
> compelling argument.
> 
> Would it cause programs to break if they get the error at listen()
> time instead of bind() time ( as the man page indicates it can )?  I
> think not.

You will definitely break programs that look for a locally available
port by iterating over bind() calls.

Sorry, this is not changing, no matter how strongly you may wish it
to.

^ permalink raw reply

* Re: Bug: mv643xxx fails with highmem
From: Russell King - ARM Linux @ 2014-12-11 20:25 UTC (permalink / raw)
  To: David Miller, Nimrod Andy, Fabio Estevam; +Cc: ezequiel.garcia, netdev
In-Reply-To: <20141211.151055.817876561546126576.davem@davemloft.net>

On Thu, Dec 11, 2014 at 03:10:55PM -0500, David Miller wrote:
> From: Russell King - ARM Linux <linux@arm.linux.org.uk>
> Date: Thu, 11 Dec 2014 19:49:20 +0000
> 
> > Commit 69ad0dd7af22 removed skb_frag_dma_map() in favour of mapping
> > all fragments with dma_map_single().  This fails when the driver is
> > used in an environment with highmem.
> 
> This change looks really buggy to me.
> 
> Unfortunately, all the changes he subsequently makes for software TSO
> support depend upon this :-/
> 
> The change is definitely wrong.

Thanks for confirming where the bug is.

Would other drivers need fixing for this as well?  Eg, fec_main.c
does the following, and this driver is used on iMX6 which can also have
highmem:

static int
fec_enet_txq_submit_frag_skb(struct fec_enet_priv_tx_q *txq,
                             struct sk_buff *skb,
                             struct net_device *ndev)
{
                bufaddr = page_address(this_frag->page.p) + this_frag->page_offset;
...
                addr = dma_map_single(&fep->pdev->dev, bufaddr, frag_len,
                                      DMA_TO_DEVICE);

-- 
FTTC broadband for 0.8mile line: currently at 9.5Mbps down 400kbps up
according to speedtest.net.

^ permalink raw reply

* RE: [PATCH net v9 0/7] cxgb4/cxgbi: misc. fixes for cxgb4i
From: Anish Bhatt @ 2014-12-11 20:24 UTC (permalink / raw)
  To: David Miller, Karen Xie
  Cc: linux-scsi@vger.kernel.org, netdev@vger.kernel.org, Hariprasad S,
	hch@infradead.org, James.Bottomley@HansenPartnership.com,
	michaelc@cs.wisc.edu
In-Reply-To: <20141211.150430.1465687238823811699.davem@davemloft.net>

> This series does not apply cleanly at all to net-next, it gets many
> rejects.

Hey Dave, this patchset was mostly bugfixes and hence meant for net where it
applies cleanly. not net-next. We can rebase to net-next and send if you're still
 willing to take it before net-next closes.
-Anish

^ permalink raw reply

* Re: bind() should not return -EADDRINUSE
From: Phillip Susi @ 2014-12-11 20:23 UTC (permalink / raw)
  To: David Miller; +Cc: netdev
In-Reply-To: <20141211.151804.2024237965934539073.davem@davemloft.net>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12/11/2014 3:18 PM, David Miller wrote:
> From: Phillip Susi <psusi@ubuntu.com> Date: Thu, 11 Dec 2014
> 15:17:12 -0500
> 
>> Says who?
> 
> Says multiple decades of precendence.

"It has always been broken, so it should stay broken" isn't a very
compelling argument.

Would it cause programs to break if they get the error at listen()
time instead of bind() time ( as the man page indicates it can )?  I
think not.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)

iQEcBAEBAgAGBQJUif1OAAoJENRVrw2cjl5RW8YH/0Rmg3JXGHJZr/z9H56F0Tfo
m9mGM5THOUIXFaCugiqea/6Y9j1qvZC4OJdoB8Ve/bDTpTa2bs3SHd81eEntVpGI
hXoeMw5RQxUuiBpKLmkWp+ma8Cl01qIADkTdRG2F/pPa8ee9xd4Lx0UGV6skUnVP
6HVuqeNxPS1xESQMpUAgO8KLGkvzB1/y8+7iBuc0fINZuox4KX8CVwzQB7d9I+G1
gf+yMaFtsDnNeGrXLKdSj7q+/yV61AgigSt3IeFIdUz+trbZa2W/6vUkBqVPB9bo
QEClO9JROTIkkl2ErUyd+bnrKTNJR0/tkOUmqf8JjQhjSnozD/u0JdoQRMvjQtk=
=PUUw
-----END PGP SIGNATURE-----

^ permalink raw reply

* Re: [PATCH v7 2/3] net: Add Keystone NetCP ethernet driver
From: Murali Karicheri @ 2014-12-11 20:21 UTC (permalink / raw)
  To: Joe Perches
  Cc: David Miller, netdev-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA, robh+dt-DgEjT+Ai2ygdnm+yROfE0A,
	grant.likely-QSEj5FYQhm4dnm+yROfE0A, WingMan Kwok
In-Reply-To: <1418322897.18092.37.camel-6d6DIl74uiNBDgjK7y7TUQ@public.gmane.org>

On 12/11/2014 01:34 PM, Joe Perches wrote:
> On Thu, 2014-12-11 at 12:17 -0500, Murali Karicheri wrote:
>> On 12/11/2014 12:01 PM, David Miller wrote:
>>> From: Murali Karicheri<m-karicheri2-l0cyMroinI0@public.gmane.org>
>>> Date: Thu, 11 Dec 2014 09:14:37 -0500
>>>
>>>> BTW, could you provide any suggestions that would help us merge this
>>>> series to upstream? This has been sitting on this list for a while
>>>> now.
>>>
>>> You simply have to continue going through the review and revision
>>> process until people no longer find problems with your changes.
>>>
>>> This could take several more weeks, you simply must be patient.
>>
>> Ok. Thanks. That is encouraging to hear!
>
> Perhaps these trivial things might be considered
Joe, David,

I will address the comments and repost a new version.

Murali
>
> (uncompiled)
> ---
>   drivers/net/ethernet/ti/netcp_core.c     |  2 +-
>   drivers/net/ethernet/ti/netcp_ethss.c    | 83 +++++++++++++++++---------------
>   drivers/net/ethernet/ti/netcp_xgbepcsr.c | 48 +++++++++---------
>   3 files changed, 71 insertions(+), 62 deletions(-)
>
> diff --git a/drivers/net/ethernet/ti/netcp_core.c b/drivers/net/ethernet/ti/netcp_core.c
> index 60ad299..8f38fe8 100644
> --- a/drivers/net/ethernet/ti/netcp_core.c
> +++ b/drivers/net/ethernet/ti/netcp_core.c
> @@ -1094,7 +1094,7 @@ static void netcp_tx_notify(void *arg)
>   	napi_schedule(&netcp->tx_napi);
>   }
>
> -static struct knav_dma_desc*
> +static struct knav_dma_desc *
>   netcp_tx_map_skb(struct sk_buff *skb, struct netcp_intf *netcp)
>   {
>   	struct knav_dma_desc *desc, *ndesc, *pdesc;
> diff --git a/drivers/net/ethernet/ti/netcp_ethss.c b/drivers/net/ethernet/ti/netcp_ethss.c
> index 036b886..3757957 100644
> --- a/drivers/net/ethernet/ti/netcp_ethss.c
> +++ b/drivers/net/ethernet/ti/netcp_ethss.c
> @@ -486,21 +486,29 @@ struct netcp_ethtool_stat {
>   	int offset;
>   };
>
> -#define GBE_STATSA_INFO(field)		"GBE_A:"#field, GBE_STATSA_MODULE,\
> -				FIELD_SIZEOF(struct gbe_hw_stats, field), \
> -				offsetof(struct gbe_hw_stats, field)
> -
> -#define GBE_STATSB_INFO(field)		"GBE_B:"#field, GBE_STATSB_MODULE,\
> -				FIELD_SIZEOF(struct gbe_hw_stats, field), \
> -				offsetof(struct gbe_hw_stats, field)
> -
> -#define GBE_STATSC_INFO(field)		"GBE_C:"#field, GBE_STATSC_MODULE,\
> -				FIELD_SIZEOF(struct gbe_hw_stats, field), \
> -				offsetof(struct gbe_hw_stats, field)
> -
> -#define GBE_STATSD_INFO(field)		"GBE_D:"#field, GBE_STATSD_MODULE,\
> -				FIELD_SIZEOF(struct gbe_hw_stats, field), \
> -				offsetof(struct gbe_hw_stats, field)
> +#define GBE_STATSA_INFO(field)						\
> +	.desc = "GBE_A:"#field,						\
> +	.type = GBE_STATSA_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
> +
> +#define GBE_STATSB_INFO(field)						\
> +	.desc = "GBE_B:"#field,						\
> +	.type = GBE_STATSB_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
> +
> +#define GBE_STATSC_INFO(field)						\
> +	.desc = "GBE_C:"#field,						\
> +	.type = GBE_STATSC_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
> +
> +#define GBE_STATSD_INFO(field)						\
> +	.desc = "GBE_D:"#field,						\
> +	.type = GBE_STATSD_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
>
>   static const struct netcp_ethtool_stat gbe13_et_stats[] = {
>   	/* GBE module A */
> @@ -645,17 +653,23 @@ static const struct netcp_ethtool_stat gbe13_et_stats[] = {
>   	{GBE_STATSD_INFO(rx_dma_overruns)},
>   };
>
> -#define XGBE_STATS0_INFO(field)	"GBE_0:"#field, XGBE_STATS0_MODULE, \
> -				FIELD_SIZEOF(struct xgbe_hw_stats, field), \
> -				offsetof(struct xgbe_hw_stats, field)
> +#define XGBE_STATS0_INFO(field)						\
> +	.desc = "GBE_0:"#field,						\
> +	.type = GBE_STATS0_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
>
> -#define XGBE_STATS1_INFO(field)	"GBE_1:"#field, XGBE_STATS1_MODULE, \
> -				FIELD_SIZEOF(struct xgbe_hw_stats, field), \
> -				offsetof(struct xgbe_hw_stats, field)
> +#define XGBE_STATS1_INFO(field)						\
> +	.desc = "GBE_1:"#field,						\
> +	.type = GBE_STATS1_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
>
> -#define XGBE_STATS2_INFO(field)	"GBE_2:"#field, XGBE_STATS2_MODULE, \
> -				FIELD_SIZEOF(struct xgbe_hw_stats, field), \
> -				offsetof(struct xgbe_hw_stats, field)
> +#define XGBE_STATS2_INFO(field)
> +	.desc = "GBE_2:"#field,						\
> +	.type = GBE_STATS2_MODULE,					\
> +	.size = FIELD_SIZEOF(struct gbe_hw_stats, field),		\
> +	.offset = offsetof(struct gbe_hw_stats, field)
>
>   static const struct netcp_ethtool_stat xgbe10_et_stats[] = {
>   	/* GBE module 0 */
> @@ -883,11 +897,11 @@ static void gbe_update_stats_ver14(struct gbe_priv *gbe_dev, uint64_t *data)
>   			case GBE_STATSA_MODULE:
>   			case GBE_STATSC_MODULE:
>   				base = gbe_statsa;
> -			break;
> +				break;
>   			case GBE_STATSB_MODULE:
>   			case GBE_STATSD_MODULE:
>   				base  = gbe_statsb;
> -			break;
> +				break;
>   			}
>
>   			p = base + gbe_dev->et_stats[j].offset;
> @@ -1639,11 +1653,8 @@ static void init_secondary_ports(struct gbe_priv *gbe_dev,
>
>   	for_each_child_of_node(node, port) {
>   		slave = devm_kzalloc(dev, sizeof(*slave), GFP_KERNEL);
> -		if (!slave) {
> -			dev_err(dev, "memomry alloc failed for secondary port(%s), skipping...\n",
> -				port->name);
> +		if (!slave)
>   			continue;
> -		}
>
>   		if (init_slave(gbe_dev, slave, port)) {
>   			dev_err(dev, "Failed to initialize secondary port(%s), skipping...\n",
> @@ -1763,10 +1774,8 @@ static int set_xgbe_ethss10_priv(struct gbe_priv *gbe_dev,
>   					  XGBE10_NUM_STAT_ENTRIES *
>   					  XGBE10_NUM_SLAVES * sizeof(u64),
>   					  GFP_KERNEL);
> -	if (!gbe_dev->hw_stats) {
> -		dev_err(gbe_dev->dev, "hw_stats memory allocation failed\n");
> +	if (!gbe_dev->hw_stats)
>   		return -ENOMEM;
> -	}
>
>   	gbe_dev->ss_version = XGBE_SS_VERSION_10;
>   	gbe_dev->sgmii_port_regs = gbe_dev->ss_regs +
> @@ -1836,10 +1845,8 @@ static int set_gbe_ethss14_priv(struct gbe_priv *gbe_dev,
>   					  GBE13_NUM_HW_STAT_ENTRIES *
>   					  GBE13_NUM_SLAVES * sizeof(u64),
>   					  GFP_KERNEL);
> -	if (!gbe_dev->hw_stats) {
> -		dev_err(gbe_dev->dev, "hw_stats memory allocation failed\n");
> +	if (!gbe_dev->hw_stats)
>   		return -ENOMEM;
> -	}
>
>   	gbe_dev->ss_version = GBE_SS_VERSION_14;
>   	gbe_dev->sgmii_port_regs = regs + GBE13_SGMII_MODULE_OFFSET;
> @@ -1995,10 +2002,10 @@ static int gbe_probe(struct netcp_device *netcp_device, struct device *dev,
>   		dev_err(gbe_dev->dev, "error initializing ale engine\n");
>   		ret = -ENODEV;
>   		goto quit;
> -	} else {
> -		dev_dbg(gbe_dev->dev, "Created a gbe ale engine\n");
>   	}
>
> +	dev_dbg(gbe_dev->dev, "Created a gbe ale engine\n");
> +
>   	/* initialize host port */
>   	gbe_init_host_port(gbe_dev);
>
> diff --git a/drivers/net/ethernet/ti/netcp_xgbepcsr.c b/drivers/net/ethernet/ti/netcp_xgbepcsr.c
> index 33571ac..d93a6a4 100644
> --- a/drivers/net/ethernet/ti/netcp_xgbepcsr.c
> +++ b/drivers/net/ethernet/ti/netcp_xgbepcsr.c
> @@ -14,6 +14,9 @@
>    * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
>    * GNU General Public License for more details.
>    */
> +
> +#define pr_fmt(fmt) "XGBE: " fmt
> +
>   #include "netcp.h"
>
>   /* XGBE registers */
> @@ -43,7 +46,7 @@ struct serdes_cfg {
>   	u32 mask;
>   };
>
> -static struct serdes_cfg cfg_phyb_1p25g_156p25mhz_cmu0[] = {
> +static const struct serdes_cfg cfg_phyb_1p25g_156p25mhz_cmu0[] = {
>   	{0x0000, 0x00800002, 0x00ff00ff},
>   	{0x0014, 0x00003838, 0x0000ffff},
>   	{0x0060, 0x1c44e438, 0xffffffff},
> @@ -54,7 +57,7 @@ static struct serdes_cfg cfg_phyb_1p25g_156p25mhz_cmu0[] = {
>   	{0x0000, 0x00000003, 0x000000ff},
>   };
>
> -static struct serdes_cfg cfg_phyb_10p3125g_156p25mhz_cmu1[] = {
> +static const struct serdes_cfg cfg_phyb_10p3125g_156p25mhz_cmu1[] = {
>   	{0x0c00, 0x00030002, 0x00ff00ff},
>   	{0x0c14, 0x00005252, 0x0000ffff},
>   	{0x0c28, 0x80000000, 0xff000000},
> @@ -76,7 +79,7 @@ static struct serdes_cfg cfg_phyb_10p3125g_156p25mhz_cmu1[] = {
>   	{0x0c00, 0x00000003, 0x000000ff},
>   };
>
> -static struct serdes_cfg cfg_phyb_10p3125g_16bit_lane[] = {
> +static const struct serdes_cfg cfg_phyb_10p3125g_16bit_lane[] = {
>   	{0x0204, 0x00000080, 0x000000ff},
>   	{0x0208, 0x0000920d, 0x0000ffff},
>   	{0x0204, 0xfc000000, 0xff000000},
> @@ -106,7 +109,7 @@ static struct serdes_cfg cfg_phyb_10p3125g_16bit_lane[] = {
>   	{0x03cc, 0x00000000, 0x000000ff},
>   };
>
> -static struct serdes_cfg cfg_phyb_10p3125g_comlane[] = {
> +static const struct serdes_cfg cfg_phyb_10p3125g_comlane[] = {
>   	{0x0a00, 0x00000800, 0x0000ff00},
>   	{0x0a84, 0x00000000, 0x000000ff},
>   	{0x0a8c, 0x00130000, 0x00ff0000},
> @@ -124,7 +127,7 @@ static struct serdes_cfg cfg_phyb_10p3125g_comlane[] = {
>   	{0x0ac0, 0x0000008b, 0x000000ff},
>   };
>
> -static struct serdes_cfg cfg_cm_c1_c2[] = {
> +static const struct serdes_cfg cfg_cm_c1_c2[] = {
>   	{0x0208, 0x00000000, 0x00000f00},
>   	{0x0208, 0x00000000, 0x0000001f},
>   	{0x0204, 0x00000000, 0x00040000},
> @@ -185,8 +188,8 @@ static void netcp_xgbe_serdes_com_enable(void __iomem *serdes_regs)
>   	}
>   }
>
> -static void netcp_xgbe_serdes_lane_enable(
> -			void __iomem *serdes_regs, int lane)
> +static void netcp_xgbe_serdes_lane_enable(void __iomem *serdes_regs,
> +					  int lane)
>   {
>   	/* Set Lane Control Rate */
>   	writel(0xe0e9e038, serdes_regs + 0x1fe0 + (4 * lane));
> @@ -230,7 +233,7 @@ static int netcp_xgbe_wait_pll_locked(void __iomem *sw_regs)
>   		cpu_relax();
>   	} while (true);
>
> -	pr_err("XGBE serdes not locked: time out.\n");
> +	pr_err("serdes not locked: time out\n");
>   	return ret;
>   }
>
> @@ -292,8 +295,7 @@ static void netcp_xgbe_serdes_reset_cdr(void __iomem *serdes_regs,
>   	u32 tmp, dlpf, tbus;
>
>   	/*Get the DLPF values */
> -	tmp = netcp_xgbe_serdes_read_select_tbus(
> -			serdes_regs, lane + 1, 5);
> +	tmp = netcp_xgbe_serdes_read_select_tbus(serdes_regs, lane + 1, 5);
>
>   	dlpf = tmp>>  2;
>
> @@ -302,10 +304,10 @@ static void netcp_xgbe_serdes_reset_cdr(void __iomem *serdes_regs,
>   		mdelay(1);
>   		reg_rmw(sig_detect_reg, VAL_SH(0, 1), MASK_WID_SH(2, 1));
>   	} else {
> -		tbus = netcp_xgbe_serdes_read_select_tbus(serdes_regs, lane +
> -							  1, 0xe);
> +		tbus = netcp_xgbe_serdes_read_select_tbus(serdes_regs,
> +							  lane + 1, 0xe);
>
> -		pr_debug("XGBE: CDR centered, DLPF: %4d,%d,%d.\n",
> +		pr_debug("CDR centered, DLPF: %4d,%d,%d\n",
>   			 tmp>>  2, tmp&  3, (tbus>>  2)&  3);
>   	}
>   }
> @@ -340,13 +342,13 @@ static int netcp_xgbe_check_link_status(void __iomem *serdes_regs,
>   		case 0:
>   			/* if good link lock the signal detect ON! */
>   			if (!loss&&  blk_lock) {
> -				pr_debug("XGBE PCSR Linked Lane: %d\n", i);
> +				pr_debug("PCSR Linked Lane: %d\n", i);
>   				reg_rmw(sig_detect_reg, VAL_SH(3, 1),
>   					MASK_WID_SH(2, 1));
>   				current_state[i] = 1;
>   			} else if (!blk_lock) {
>   				/* if no lock, then reset CDR */
> -				pr_debug("XGBE PCSR Recover Lane: %d\n", i);
> +				pr_debug("PCSR Recover Lane: %d\n", i);
>   				netcp_xgbe_serdes_reset_cdr(serdes_regs,
>   							    sig_detect_reg, i);
>   			}
> @@ -361,10 +363,10 @@ static int netcp_xgbe_check_link_status(void __iomem *serdes_regs,
>   			break;
>
>   		case 2:
> -			if (blk_lock)
> +			if (blk_lock) {
>   				/* Nope just noise */
>   				current_state[i] = 1;
> -			else {
> +			} else {
>   				/* Lost the block lock, reset CDR if it is
>   				 * not centered and go back to sync state
>   				 */
> @@ -375,7 +377,7 @@ static int netcp_xgbe_check_link_status(void __iomem *serdes_regs,
>   			break;
>
>   		default:
> -			pr_err("XGBE: unknown current_state[%d] %d\n",
> +			pr_err("unknown current_state[%d] %d\n",
>   			       i, current_state[i]);
>   			break;
>   		}
> @@ -417,19 +419,19 @@ static int netcp_xgbe_serdes_check_lane(void __iomem *serdes_regs,
>   			break;
>
>   		if (lane_down[0])
> -			pr_debug("XGBE: detected link down on lane 0\n");
> +			pr_debug("detected link down on lane 0\n");
>
>   		if (lane_down[1])
> -			pr_debug("XGBE: detected link down on lane 1\n");
> +			pr_debug("detected link down on lane 1\n");
>
>   		if (++retries>  1) {
> -			pr_debug("XGBE: timeout waiting for serdes link up\n");
> +			pr_debug("timeout waiting for serdes link up\n");
>   			return -ETIMEDOUT;
>   		}
>   		mdelay(100);
>   	} while (!link_up);
>
> -	pr_debug("XGBE: PCSR link is up\n");
> +	pr_debug("PCSR link is up\n");
>   	return 0;
>   }
>
> @@ -494,7 +496,7 @@ int netcp_xgbe_serdes_init(void __iomem *serdes_regs, void __iomem *xgbe_regs)
>   	/* read COMLANE bits 4:0 */
>   	val = readl(serdes_regs + 0xa00);
>   	if (val&  0x1f) {
> -		pr_debug("XGBE: serdes already in operation - reset\n");
> +		pr_debug("serdes already in operation - reset\n");
>   		netcp_xgbe_reset_serdes(serdes_regs);
>   	}
>   	return netcp_xgbe_serdes_config(serdes_regs, xgbe_regs);
>
>
>


-- 
Murali Karicheri
Linux Kernel, Texas Instruments
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply

* Re: bind() should not return -EADDRINUSE
From: David Miller @ 2014-12-11 20:18 UTC (permalink / raw)
  To: psusi; +Cc: netdev
In-Reply-To: <5489FBC8.4070706@ubuntu.com>

From: Phillip Susi <psusi@ubuntu.com>
Date: Thu, 11 Dec 2014 15:17:12 -0500

> Says who?

Says multiple decades of precendence.

^ permalink raw reply

* Re: bind() should not return -EADDRINUSE
From: Phillip Susi @ 2014-12-11 20:17 UTC (permalink / raw)
  To: David Miller; +Cc: netdev
In-Reply-To: <20141211.151302.686998496408277043.davem@davemloft.net>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12/11/2014 3:13 PM, David Miller wrote:
> 
> But you don't know ahead of time what the processes are going to 
> do, that's the problem.
> 
> You cannot leave the port available and pretend to another process 
> that he will be able to use it.
> 
> Port allocation failures must be signalled at bind() time.

Says who?  The man pages for both listen() and connect() say they can
return EADDRINUSE.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)

iQEcBAEBAgAGBQJUifvIAAoJENRVrw2cjl5R+r8H/jb84r9KUgMQcfFAPB4aYQKt
ou188Bpv6aa1AB1yt99il8bulvXMO5m0NuLG8NcYIDnt0zo1xaVrbxelNHIkx0XQ
Gj67Ozc+yMOQ6izHUPMNgB9lI3q/GBhI6dt5/5NnIeAx4VzCQIhT1nKT6LRo4J6z
k6R7vyXrm9M7X0A3hh7Dpapv/JWuzZfZYOZP+JQP/BSLorEX0+pZHoqOl0Cy+bwo
rp/oaAAaQe+cX95dplXLVmXoh6JxjBTkXqWEEHTnNNbz3LsY+e7aokz3Pl9kQw3M
hn1q9PSC+JMhxCI3AOgukIwlK3ps7y78PiQHxds/K/ZNVzaaeJAY+FryppUijPk=
=/oDW
-----END PGP SIGNATURE-----

^ permalink raw reply

* Re: [PATCH net-next] Avoid reducing cwnd when ACK+DSACK is received
From: David Miller @ 2014-12-11 20:14 UTC (permalink / raw)
  To: sebastien.barre; +Cc: netdev, gregory.detal, nanditad, ycheng
In-Reply-To: <1418327890-368-1-git-send-email-sebastien.barre@uclouvain.be>


The net-next tree is closed, therefore it is not appropriate to submit net-next
changes at this time.

Thanks.

^ permalink raw reply

* Re: Bug: mv643xxx fails with highmem
From: Ezequiel Garcia @ 2014-12-11 20:12 UTC (permalink / raw)
  To: David Miller, linux; +Cc: netdev
In-Reply-To: <20141211.151055.817876561546126576.davem@davemloft.net>

On 12/11/2014 05:10 PM, David Miller wrote:
> From: Russell King - ARM Linux <linux@arm.linux.org.uk>
> Date: Thu, 11 Dec 2014 19:49:20 +0000
> 
>> Commit 69ad0dd7af22 removed skb_frag_dma_map() in favour of mapping
>> all fragments with dma_map_single().  This fails when the driver is
>> used in an environment with highmem.
> 
> This change looks really buggy to me.
> 
> Unfortunately, all the changes he subsequently makes for software TSO
> support depend upon this :-/
> 
> The change is definitely wrong.
> 

Got it. I'll take a closer look and will try to think a fix for this.

-- 
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com

^ permalink raw reply

* Re: bind() should not return -EADDRINUSE
From: David Miller @ 2014-12-11 20:13 UTC (permalink / raw)
  To: psusi; +Cc: netdev
In-Reply-To: <5489F598.9020708@ubuntu.com>

From: Phillip Susi <psusi@ubuntu.com>
Date: Thu, 11 Dec 2014 14:50:48 -0500

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> On 12/11/2014 2:23 PM, David Miller wrote:
>> From: Phillip Susi <psusi@ubuntu.com> Date: Thu, 11 Dec 2014
>> 14:19:11 -0500
>> 
>>> Attempting to establish a connection to a remote host using the
>>> same local port, but a different remote port as the previous
>>> connection ( that is still in TIME_WAIT ) results in bind()
>>> returning -EADDRINUSE. By changing the remote port, you avoid the
>>> conflict with the other connection that is in TIME_WAIT, but
>>> since the remote port is not known when bind() is called, it
>>> incorrectly returns -EADDRINUSE.  This check should not be done
>>> in bind(), but deferred until the remote port is known in the
>>> call to connect(), or listen().
>> 
>> Bind has to allocate and hold from everyone else on the system the 
>> local port at bind() time, so we cannot defer this decision.
> 
> What on earth for?  If two processes are going to connect to different
> remotes using the same source, that is perfectly fine.  The only
> contention is if two processes want to listen() with the same local
> addr and wildcard remote.

But you don't know ahead of time what the processes are going to
do, that's the problem.

You cannot leave the port available and pretend to another process
that he will be able to use it.

Port allocation failures must be signalled at bind() time.

^ permalink raw reply

* Re: Bug: mv643xxx fails with highmem
From: David Miller @ 2014-12-11 20:10 UTC (permalink / raw)
  To: linux; +Cc: ezequiel.garcia, netdev
In-Reply-To: <20141211194920.GR11285@n2100.arm.linux.org.uk>

From: Russell King - ARM Linux <linux@arm.linux.org.uk>
Date: Thu, 11 Dec 2014 19:49:20 +0000

> Commit 69ad0dd7af22 removed skb_frag_dma_map() in favour of mapping
> all fragments with dma_map_single().  This fails when the driver is
> used in an environment with highmem.

This change looks really buggy to me.

Unfortunately, all the changes he subsequently makes for software TSO
support depend upon this :-/

The change is definitely wrong.

^ permalink raw reply

* Re: [net] gre: fix the inner mac header in nbma gre tunnels xmit path
From: David Miller @ 2014-12-11 20:07 UTC (permalink / raw)
  To: timo.teras; +Cc: netdev, therbert, alexander.h.duyck
In-Reply-To: <20141211214456.7cc621e4@vostro>

From: Timo Teras <timo.teras@iki.fi>
Date: Thu, 11 Dec 2014 21:44:56 +0200

> On Thu, 11 Dec 2014 14:36:27 -0500 (EST)
> David Miller <davem@davemloft.net> wrote:
> 
>> From: Timo Teräs <timo.teras@iki.fi>
>> Date: Thu, 11 Dec 2014 09:14:39 +0200
>> 
>> > @@ -266,6 +262,7 @@ static netdev_tx_t ipgre_xmit(struct sk_buff
>> > *skb,
>> >  		 * to gre header.
>> >  		 */
>> >  		skb_pull(skb, tunnel->hlen + sizeof(struct iphdr));
>> > +		skb_reset_mac_header(mac);
>> 
>> Please explain to me how this compiles, let alone be functionally
>> tested.
> 
> Sorry. I made the change twice; once on the build box. And again on my
> git checkout on work station. Must've been on seriously coffee deprived
> state.
> 
> Should be obviously:
> +		skb_reset_mac_header(skb);
> 
> Is there other comments on it?

I don't care where you applied the patch, if you didn't type make after
making the change, that is extremely careless.

^ permalink raw reply

* [PATCH net-next] Avoid reducing cwnd when ACK+DSACK is received
From: Sébastien Barré @ 2014-12-11 19:58 UTC (permalink / raw)
  To: David Miller
  Cc: Sébastien Barré, netdev, Gregory Detal,
	Nandita Dukkipati, Yuchung Cheng

When the peer has delayed ack enabled, it may reply to a probe with an
ACK+D-SACK, with ack value set to tlp_high_seq. In the current code,
such ACK+DSACK will be missed and only at next, higher ack will the TLP
episode be considered done. Since the DSACK is not present anymore,
this will cost a cwnd reduction.

This patch ensures that this scenario does not cause a cwnd reduction, since
receiving an ACK+DSACK indicates that both the initial segment and the probe
have been received by the peer.

Cc: Gregory Detal <gregory.detal@uclouvain.be>
Cc: Nandita Dukkipati <nanditad@google.com>
Cc: Yuchung Cheng <ycheng@google.com>
Signed-off-by: Sébastien Barré <sebastien.barre@uclouvain.be>

---
 net/ipv4/tcp_input.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c
index 075ab4d..fb007cc 100644
--- a/net/ipv4/tcp_input.c
+++ b/net/ipv4/tcp_input.c
@@ -3369,23 +3369,23 @@ static void tcp_process_tlp_ack(struct sock *sk, u32 ack, int flag)
 
 	/* Mark the end of TLP episode on receiving TLP dupack or when
 	 * ack is after tlp_high_seq.
+	 * With delayed acks, we may also get a regular ACK+DSACK, in which
+	 * case we don't want to reduce the cwnd either.
 	 */
-	if (is_tlp_dupack) {
+	if (is_tlp_dupack ||
+	    !before(ack, tp->tlp_high_seq) && (flag & FLAG_DSACKING_ACK)) {
 		tp->tlp_high_seq = 0;
 		return;
 	}
 
 	if (after(ack, tp->tlp_high_seq)) {
 		tp->tlp_high_seq = 0;
-		/* Don't reduce cwnd if DSACK arrives for TLP retrans. */
-		if (!(flag & FLAG_DSACKING_ACK)) {
-			tcp_init_cwnd_reduction(sk);
-			tcp_set_ca_state(sk, TCP_CA_CWR);
-			tcp_end_cwnd_reduction(sk);
-			tcp_try_keep_open(sk);
-			NET_INC_STATS_BH(sock_net(sk),
-					 LINUX_MIB_TCPLOSSPROBERECOVERY);
-		}
+		tcp_init_cwnd_reduction(sk);
+		tcp_set_ca_state(sk, TCP_CA_CWR);
+		tcp_end_cwnd_reduction(sk);
+		tcp_try_keep_open(sk);
+		NET_INC_STATS_BH(sock_net(sk),
+				 LINUX_MIB_TCPLOSSPROBERECOVERY);
 	}
 }
 
-- 
tg: (52c9b12..) net-next/tlp-dsack-handling (depends on: net-next/master)

^ permalink raw reply related

* Re: [PATCH net v9 0/7] cxgb4/cxgbi: misc. fixes for cxgb4i
From: David Miller @ 2014-12-11 20:04 UTC (permalink / raw)
  To: kxie; +Cc: linux-scsi, netdev, hariprasad, anish, hch, James.Bottomley,
	michaelc
In-Reply-To: <201412111525.sBBFPbfn012920@localhost6.localdomain6>

From: Karen Xie <kxie@chelsio.com>
Date: Thu, 11 Dec 2014 07:25:37 -0800

> This patch set fixes cxgb4i's tx credit calculation and adds handling of
> additional rx message and negative advice types. It also removes the duplicate
> code in cxgb4i to set the outgoing queues of a packet. 

This series does not apply cleanly at all to net-next, it gets many
rejects.

^ permalink raw reply

* Re: [PATCH net v2] Fix race condition between vxlan_sock_add and vxlan_sock_release
From: David Miller @ 2014-12-11 19:57 UTC (permalink / raw)
  To: mleitner; +Cc: netdev
In-Reply-To: <125fcb71bfb239711f03d3344b4275b304db6bb8.1418298054.git.mleitner@redhat.com>

From: Marcelo Ricardo Leitner <mleitner@redhat.com>
Date: Thu, 11 Dec 2014 10:02:22 -0200

> Currently, when trying to reuse a socket, vxlan_sock_add will grab
> vn->sock_lock, locate a reusable socket, inc refcount and release
> vn->sock_lock.
> 
> But vxlan_sock_release() will first decrement refcount, and then grab
> that lock. refcnt operations are atomic but as currently we have
> deferred works which hold vs->refcnt each, this might happen, leading to
> a use after free (specially after vxlan_igmp_leave):
> 
>   CPU 1                            CPU 2
> 
> deferred work                    vxlan_sock_add
>   ...                              ...
>                                    spin_lock(&vn->sock_lock)
>                                    vs = vxlan_find_sock();
>   vxlan_sock_release
>     dec vs->refcnt, reaches 0
>     spin_lock(&vn->sock_lock)
>                                    vxlan_sock_hold(vs), refcnt=1
>                                    spin_unlock(&vn->sock_lock)
>     hlist_del_rcu(&vs->hlist);
>     vxlan_notify_del_rx_port(vs)
>     spin_unlock(&vn->sock_lock)
> 
> 
> So when we look for a reusable socket, we check if it wasn't freed
> already before reusing it.
> 
> Signed-off-by: Marcelo Ricardo Leitner <mleitner@redhat.com>
> Fixes: 7c47cedf43a8b3 ("vxlan: move IGMP join/leave to work queue")

Applied and queued up for -stable, thanks.

^ permalink raw reply

* Re: [PATCH 1/1] net/macb: fix compilation warning for print_hex_dump() called with skb->mac_header
From: David Miller @ 2014-12-11 19:52 UTC (permalink / raw)
  To: cyrille.pitchen
  Cc: nicolas.ferre, linux-arm-kernel, netdev, soren.brinkmann,
	linux-kernel
In-Reply-To: <efa28485b430e77f5254248cb396da431d03fc5b.1418292741.git.cyrille.pitchen@atmel.com>

From: Cyrille Pitchen <cyrille.pitchen@atmel.com>
Date: Thu, 11 Dec 2014 11:15:54 +0100

> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>

Applied, thanks.

^ permalink raw reply

* Re: bind() should not return -EADDRINUSE
From: Phillip Susi @ 2014-12-11 19:50 UTC (permalink / raw)
  To: David Miller; +Cc: netdev
In-Reply-To: <20141211.142355.854082841833367081.davem@davemloft.net>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12/11/2014 2:23 PM, David Miller wrote:
> From: Phillip Susi <psusi@ubuntu.com> Date: Thu, 11 Dec 2014
> 14:19:11 -0500
> 
>> Attempting to establish a connection to a remote host using the
>> same local port, but a different remote port as the previous
>> connection ( that is still in TIME_WAIT ) results in bind()
>> returning -EADDRINUSE. By changing the remote port, you avoid the
>> conflict with the other connection that is in TIME_WAIT, but
>> since the remote port is not known when bind() is called, it
>> incorrectly returns -EADDRINUSE.  This check should not be done
>> in bind(), but deferred until the remote port is known in the
>> call to connect(), or listen().
> 
> Bind has to allocate and hold from everyone else on the system the 
> local port at bind() time, so we cannot defer this decision.

What on earth for?  If two processes are going to connect to different
remotes using the same source, that is perfectly fine.  The only
contention is if two processes want to listen() with the same local
addr and wildcard remote.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)

iQEcBAEBAgAGBQJUifWYAAoJENRVrw2cjl5RpckH/2g9V0p3SFNvf1qmR1nxZjJ6
R19eosdoWvCL6B2pIqwvpy64ACqTf6MS3NrdZt6TwSz+8OKqBj/D8+IpKcAdo5kU
Yzhl3qASkm17HTeOmGhw00pqJkD4FYzzwb8hw/OxwxWUwpVLvv+nMYHhF7vwgOy6
h90Kmj6ycOeY/+sX5Woe5RheKq+AlDqJGAELk1Vs9lrRDDa/3o/HqEQX5HNsohyC
ib2dJRAdCuNN9KjSKuVLnCu4Tf1UB5W+efSK21qN/s1r0a0RWXMe2ph6JrYQsg2e
H2nl7Ifiv/4VbuvRkabSsrge8bJtw76c2uMpxw1GHNUN1rNnxhGAj4J1oOIp4rQ=
=LXdQ
-----END PGP SIGNATURE-----

^ permalink raw reply

* Bug: mv643xxx fails with highmem
From: Russell King - ARM Linux @ 2014-12-11 19:49 UTC (permalink / raw)
  To: Ezequiel Garcia, David S. Miller; +Cc: netdev

Commit 69ad0dd7af22 removed skb_frag_dma_map() in favour of mapping
all fragments with dma_map_single().  This fails when the driver is
used in an environment with highmem.

With this patch in place in 3.18:

diff --git a/drivers/net/ethernet/marvell/mv643xx_eth.c b/drivers/net/ethernet/marvell/mv643xx_eth.c
index d44560d1d268..14d1fc9ff485 100644
--- a/drivers/net/ethernet/marvell/mv643xx_eth.c
+++ b/drivers/net/ethernet/marvell/mv643xx_eth.c
@@ -882,7 +882,9 @@ static void txq_submit_frag_skb(struct tx_queue *txq, struct sk_buff *skb)
 		void *addr;
  
 		this_frag = &skb_shinfo(skb)->frags[frag];
+		BUG_ON(PageHighMem(this_frag->page.p));
 		addr = page_address(this_frag->page.p) + this_frag->page_offset;
+		BUG_ON(!addr);
 		tx_index = txq->tx_curr_desc++;
 		if (txq->tx_curr_desc == txq->tx_ring_size)
 			txq->tx_curr_desc = 0;

I regularly hit the first BUG_ON().  Without the BUG_ON(), the machine
either freezes or oopses in the DMA API functions due to them being
passed an invalid struct page *.

So, I'm unclear whether this is a driver bug, or whether it's a core
netdev bug: should netdev be passing skbuffs with highmem pages
attached when the driver has NETIF_F_HIGHDMA clear, or is Ezequiel's
patch removing the ability to map highmem pages from this driver
incorrect?

Here's the ethtool -k eth0 output for this driver:

Features for eth0:
rx-checksumming: on
tx-checksumming: on
        tx-checksum-ipv4: on
        tx-checksum-ip-generic: off [fixed]
        tx-checksum-ipv6: off [fixed]
        tx-checksum-fcoe-crc: off [fixed]
        tx-checksum-sctp: off [fixed]
scatter-gather: on
        tx-scatter-gather: on
        tx-scatter-gather-fraglist: off [fixed]
tcp-segmentation-offload: on
        tx-tcp-segmentation: on
        tx-tcp-ecn-segmentation: off [fixed]
        tx-tcp6-segmentation: off [fixed]
udp-fragmentation-offload: off [fixed]
generic-segmentation-offload: on
generic-receive-offload: on
large-receive-offload: off [fixed]
rx-vlan-offload: off [fixed]
tx-vlan-offload: off [fixed]
ntuple-filters: off [fixed]
receive-hashing: off [fixed]
highdma: off [fixed]
rx-vlan-filter: off [fixed]
vlan-challenged: off [fixed]
tx-lockless: off [fixed]
netns-local: off [fixed]
tx-gso-robust: off [fixed]
tx-fcoe-segmentation: off [fixed]
tx-gre-segmentation: off [fixed]
tx-ipip-segmentation: off [fixed]
tx-sit-segmentation: off [fixed]
tx-udp_tnl-segmentation: off [fixed]
tx-mpls-segmentation: off [fixed]
fcoe-mtu: off [fixed]
tx-nocache-copy: off
loopback: off [fixed]
rx-fcs: off [fixed]
rx-all: off [fixed]
tx-vlan-stag-hw-insert: off [fixed]
rx-vlan-stag-hw-parse: off [fixed]
rx-vlan-stag-filter: off [fixed]
l2-fwd-offload: off [fixed]
busy-poll: off [fixed]

Thanks.

-- 
FTTC broadband for 0.8mile line: currently at 9.5Mbps down 400kbps up
according to speedtest.net.

^ permalink raw reply related

* Re: [PATCH V2 net-next 00/10] mlx4 driver update
From: David Miller @ 2014-12-11 19:48 UTC (permalink / raw)
  To: ogerlitz; +Cc: netdev, matanb, amirv, talal, jackm
In-Reply-To: <1418288280-334-1-git-send-email-ogerlitz@mellanox.com>

From: Or Gerlitz <ogerlitz@mellanox.com>
Date: Thu, 11 Dec 2014 10:57:50 +0200

> This series from Matan, Jenny, Dotan and myself is mostly about adding
> support to a new performance optimized flow steering mode (patches 4-10).
> 
> The 1st two patches are small fixes (one for VXLAN and one for SRIOV),
> and the third patch is a fix to avoid hard-lockup situation when many
> (hunderds) processes holding user-space QPs/CQs get events.
> 
> Matan and Or. 

Series applied, thanks.

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox