Re: [PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-19 Thread Feng Gao
Sorry, I forget to modify the title. I will sent another update. On Sat, Aug 20, 2016 at 2:28 AM, Guillaume Nault wrote: > On Fri, Aug 19, 2016 at 05:55:26PM +0800, f...@ikuai8.com wrote: >> From: Gao Feng >> >> 1. Use PPP_ALLSTATIONS/PPP_UI instead of literal 0xff/0x03; >> 2. Use one static con

Re: [PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-19 Thread David Miller
From: f...@ikuai8.com Date: Thu, 18 Aug 2016 15:05:19 +0800 > @@ -138,6 +138,8 @@ static const struct ppp_channel_ops pppol2tp_chan_ops = { > > static const struct proto_ops pppol2tp_ops; > > +static const unsigned char fixed_ppphdr[2] = {PPP_ALLSTATIONS, PPP_UI}; > + > /* Helpers to obtain

Re: [PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-19 Thread Guillaume Nault
On Fri, Aug 19, 2016 at 05:55:26PM +0800, f...@ikuai8.com wrote: > From: Gao Feng > > 1. Use PPP_ALLSTATIONS/PPP_UI instead of literal 0xff/0x03; > 2. Use one static const global fixed_ppphdr instead of two same > static variable ppph in two different functions; > 3. Use SEND_SHUTDOWN instead of

[PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-19 Thread fgao
From: Gao Feng 1. Use PPP_ALLSTATIONS/PPP_UI instead of literal 0xff/0x03; 2. Use one static const global fixed_ppphdr instead of two same static variable ppph in two different functions; 3. Use SEND_SHUTDOWN instead of literal 2; Signed-off-by: Gao Feng --- v1: Initial patch net/l2tp/l2tp_p

Re: [PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-18 Thread Guillaume Nault
On Thu, Aug 18, 2016 at 03:05:19PM +0800, f...@ikuai8.com wrote: > From: Gao Feng > > 1. Use PPP_ALLSTATIONS/PPP_UI instead of literal 0xff/0x03; > 2. Use one static const global fixed_ppphdr instead of two same > static variable ppph in two different functions; > 3. Use SEND_SHUTDOWN instead of

Re: [PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-18 Thread Feng Gao
On Fri, Aug 19, 2016 at 2:41 AM, Guillaume Nault wrote: > On Thu, Aug 18, 2016 at 03:05:19PM +0800, f...@ikuai8.com wrote: >> From: Gao Feng >> >> 1. Use PPP_ALLSTATIONS/PPP_UI instead of literal 0xff/0x03; >> 2. Use one static const global fixed_ppphdr instead of two same >> static variable ppph

[PATCH v1 1/1] l2tp: Use existing macros instead of literal number

2016-08-18 Thread fgao
From: Gao Feng 1. Use PPP_ALLSTATIONS/PPP_UI instead of literal 0xff/0x03; 2. Use one static const global fixed_ppphdr instead of two same static variable ppph in two different functions; 3. Use SEND_SHUTDOWN instead of literal 2; Signed-off-by: Gao Feng --- v1: Initial patch net/l2tp/l2tp_p