Re: [PATCH v3 net-next] l2tp: Refactor the codes with existing macros instead of literal number

2016-08-21 Thread Philp Prindeville
Inline On 08/20/2016 09:52 AM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng Use PPP_ALLSTATIONS, PPP_UI, and SEND_SHUTDOWN instead of 0xff, 0x03, and 2 separately. Signed-off-by: Gao Feng --- v3: Modify the subject; v2: Only replace the literal number with macros according

Re: [PATCH v1 1/2] pptp: Use macro and sizeof instead of literal number

2016-08-19 Thread Philp Prindeville
Inline... On 08/17/2016 10:47 PM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng Use existing macros like PPP_ADDRESS, SC_COMP_PROT and sizeof fixed variables instead of original literal number to enhance readbility. BTW, the original pptp_rcv uses literal number "12" as the param

Re: [PATCH 1/1] ppp: Fix one deadlock issue of PPP when send frame

2016-08-18 Thread Philp Prindeville
On 08/18/2016 09:05 AM, Feng Gao wrote: On Thu, Aug 18, 2016 at 10:11 PM, Philp Prindeville wrote: >Feng, > >If the CPU can already be holding the lock, that implies re-entrancy. >What's to stop the first flow of code which acquired the lock from releasing >it again be

Re: [PATCH v1 1/1] pppoe: l2tp: the PPPOX_CONNECTED should be used with bit operation

2016-08-18 Thread Philp Prindeville
Reviewed-by: Philip Prindeville On 08/17/2016 07:59 PM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng There are some codes in pppoe and l2tp which use the PPPOX_CONNECTED as the value including assignment and condition check. They should keep consistent with other codes. Signed-

Re: [PATCH 1/1] ppp: Fix one deadlock issue of PPP when send frame

2016-08-18 Thread Philp Prindeville
Feng, If the CPU can already be holding the lock, that implies re-entrancy. What's to stop the first flow of code which acquired the lock from releasing it again before the 2nd flow is done? Is the 2nd flow running at a higher priority or with interrupts disabled? It seems unlikely to me t

Re: [PATCH v1 1/1] pptp: Refactor the struct and macros of PPTP codes

2016-08-12 Thread Philp Prindeville
On 08/12/2016 10:30 AM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng 1. Use struct gre_base_hdr directly in pptp_gre_header instead of duplicated members; 2. Use existing macros like GRE_KEY, GRE_SEQ, and so on instead of duplicated macros defined by PPTP; 3. Add new macros like

Re: [PATCH v6 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-09 Thread Philp Prindeville
On 08/08/2016 10:38 PM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng The PPTP is encapsulated by GRE header with that GRE_VERSION bits must contain one. But current GRE RPS needs the GRE_VERSION must be zero. So RPS does not work for PPTP traffic. In my test environment, there ar

Re: [PATCH v4 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-08 Thread Philp Prindeville
= __skb_header_pointer(skb, nhoff, sizeof(_hdr), data, hlen, &_hdr); BTW, the original codes define one local stuct gre_hdr. Now I use the unified struct gre_base_hdr instead of it. Best Regards Feng On Mon, Aug 8, 2016 at 11:27 AM, Philp Prindeville wrote: Feng, An anonymous structure is defined here: h

Re: [PATCH v4 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-07 Thread Philp Prindeville
Philp, Forgive my poor English, I am not clear about the comment #1. "Can you make gre_base_hdr be anonymous?". +struct gre_full_hdr { + struct gre_base_hdr fixed_header; Do you mean make the member "fixed_header" as anonymous or not? Best Regards Feng On Mon, Aug

Re: [PATCH v4 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-07 Thread Philp Prindeville
Inline... On 08/04/2016 01:06 AM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng The PPTP is encapsulated by GRE header with that GRE_VERSION bits must contain one. But current GRE RPS needs the GRE_VERSION must be zero. So RPS does not work for PPTP traffic. In my test environme

Re: [PATCH v3 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-03 Thread Philp Prindeville
Inline On 08/03/2016 05:58 PM, Feng Gao wrote: inline comment. There are two comments that I am not clear. Best Regards Feng On Thu, Aug 4, 2016 at 4:43 AM, Philip Prindeville wrote: Inlineā€¦ On Aug 3, 2016, at 8:52 AM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng The PPTP

Re: [PATCH 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-02 Thread Philp Prindeville
Inline... On 08/02/2016 12:10 AM, Feng Gao wrote: Thanks. Because the original GRE uses the literal number directly, so I follow this style. Then I have two questions. 1. pptp_gre_header is defined in "drivers/net/ppp/pptp.c"; If we want to use it, need to create one new header file, is it ok

Re: [PATCH 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-08-01 Thread Philp Prindeville
Inline... Main issue in a nutshell is I don't like using "4" instead of "sizeof(my_32bit_header_field_here)". On 07/28/2016 01:14 AM, f...@48lvckh6395k16k5.yundunddos.com wrote: From: Gao Feng The PPTP is encapsulated by GRE header with that GRE_VERSION bits must contain one. But current G

Re: [PATCH 1/1] rps: Inspect PPTP encapsulated by GRE to get flow hash

2016-07-27 Thread Philp Prindeville
Inline... On 07/27/2016 06:04 PM, Tom Herbert wrote: On Wed, Jul 27, 2016 at 4:42 PM, wrote: From: Gao Feng The PPTP is encapsulated by GRE header with that GRE_VERSION bits must contain one. But current GRE RPS needs the GRE_VERSION must be zero. So RPS does not work for PPTP traffic. In