Re: [PATCH 1/1] net: ethernet: broadcom: fix improper return value

2016-12-05 Thread David Miller
From: Pan Bian Date: Sun, 4 Dec 2016 14:29:29 +0800 > From: Pan Bian > > Marco BNX2X_ALLOC_AND_SET(arr, lbl, func) calls kmalloc() to allocate > memory, and jumps to label "lbl" if the allocation fails. Label "lbl" > first cleans memory and then

Re: [PATCH 1/1] net: ethernet: broadcom: fix improper return value

2016-12-05 Thread David Miller
From: Pan Bian Date: Sun, 4 Dec 2016 14:29:29 +0800 > From: Pan Bian > > Marco BNX2X_ALLOC_AND_SET(arr, lbl, func) calls kmalloc() to allocate > memory, and jumps to label "lbl" if the allocation fails. Label "lbl" > first cleans memory and then returns variable rc. Before calling the >

RE: [PATCH 1/1] net: ethernet: broadcom: fix improper return value

2016-12-04 Thread Kalderon, Michal
> From: Pan Bian > > Marco BNX2X_ALLOC_AND_SET(arr, lbl, func) calls kmalloc() to allocate > memory, and jumps to label "lbl" if the allocation fails. Label "lbl" > first cleans memory and then returns variable rc. Before calling the macro, > the > value of variable rc is

RE: [PATCH 1/1] net: ethernet: broadcom: fix improper return value

2016-12-04 Thread Kalderon, Michal
> From: Pan Bian > > Marco BNX2X_ALLOC_AND_SET(arr, lbl, func) calls kmalloc() to allocate > memory, and jumps to label "lbl" if the allocation fails. Label "lbl" > first cleans memory and then returns variable rc. Before calling the macro, > the > value of variable rc is 0. Because 0 means no

[PATCH 1/1] net: ethernet: broadcom: fix improper return value

2016-12-03 Thread Pan Bian
From: Pan Bian Marco BNX2X_ALLOC_AND_SET(arr, lbl, func) calls kmalloc() to allocate memory, and jumps to label "lbl" if the allocation fails. Label "lbl" first cleans memory and then returns variable rc. Before calling the macro, the value of variable rc is 0. Because 0

[PATCH 1/1] net: ethernet: broadcom: fix improper return value

2016-12-03 Thread Pan Bian
From: Pan Bian Marco BNX2X_ALLOC_AND_SET(arr, lbl, func) calls kmalloc() to allocate memory, and jumps to label "lbl" if the allocation fails. Label "lbl" first cleans memory and then returns variable rc. Before calling the macro, the value of variable rc is 0. Because 0 means no error, the