Hi,

Great!
Many thanks for your posting!


On 2017年02月25日 06:29, surlyjake wrote:
> Here you go. (although Iwase did the hard work).
> 
> I'm following the 'CONTRIBUTING' guidelines which state not to use github 
> pull requests, but i notice that there are still quite a few pull requests 
> active there. Are github pull requests OK to use from now on?

Sorry for the inconvenience, the guidelines on 'CONTRIBUTING.rst' seems to be 
very old...
(We need to update it. Other developer has already pointed out through.)

As you know, currently, we do not use the Pull Request on GitHub, but using the 
Git formatted style
patches on this mailing list.
(The existing PR should be reposted to this mailing list and closed, I guess.)

Would you mind re-formatting your patch in the following way?
e.g.)
  # Create a branch if needed.
  $ git checkout -b <your branch>

  # Do Coding features.
    <... some modifications ...>

  # Commit your modifications.
  $ git add <modified files>
  $ git commit -s
  
  # Format patches. ("N" means the number of commits to be included)
  $ git format-patch HEAD~N

  # Then, you can use *.patch for submitting!
  # By Mailer or "git send-email" command like:
  $ git send-email --to="[email protected]" *.patch


Thanks,
Iwase


> 
> This defines the masks as in OVS, then specifies the different frag match 
> values for easy usage.
> 
> diff --git a/ryu/ofproto/nicira_ext.py b/ryu/ofproto/nicira_ext.py
> index 64b570fc..411ed48a 100644
> --- a/ryu/ofproto/nicira_ext.py
> +++ b/ryu/ofproto/nicira_ext.py
> @@ -277,6 +277,18 @@ NX_NAT_RANGE_IPV6_MAX = 1 << 3
>  NX_NAT_RANGE_PROTO_MIN = 1 << 4
>  NX_NAT_RANGE_PROTO_MAX = 1 << 5
>  
> +# nx ip_frag constants
> +FLOW_NW_FRAG_ANY = 1 << 0    # Set for any IP frag.
> +FLOW_NW_FRAG_LATER = 1 << 1  # Set for IP frag with nonzero offset.
> +FLOW_NW_FRAG_MASK = FLOW_NW_FRAG_ANY | FLOW_NW_FRAG_LATER
> +
> +# nx ip_frag match values
> +NXM_IP_FRAG_NO = (0, FLOW_NW_FRAG_MASK)
> +NXM_IP_FRAG_YES = (FLOW_NW_FRAG_ANY, FLOW_NW_FRAG_ANY)
> +NXM_IP_FRAG_FIRST = (FLOW_NW_FRAG_ANY, FLOW_NW_FRAG_MASK)
> +NXM_IP_FRAG_LATER = (FLOW_NW_FRAG_LATER, FLOW_NW_FRAG_LATER)
> +NXM_IP_FRAG_NOT_LATER = (0, FLOW_NW_FRAG_LATER)
> +
>  
>  def ofs_nbits(start, end):
>      """
> 
> 
> On Thu, Feb 16, 2017 at 8:29 PM Iwase Yusuke <[email protected] 
> <mailto:[email protected]>> wrote:
> 
>     Hi,
> 
>     Thank you for your reporting!
> 
> 
>     On 2017年02月17日 08:51, surlyjake wrote:
>     > http://ryu.readthedocs.io/en/latest/nicira_ext_ref.html?highlight=frag 
> indicates that ryu can make an 'ip_frag' match, but doesnt define the mapping 
> between integers and the five options (from 
> http://manpages.ubuntu.com/manpages/precise/man8/ovs-ofctl.8.html):
>     >     no Matches only non-fragmented packets.
>     >     yes Matches all fragments.
>     >     first Matches only fragments with offset 0.
>     >     later Matches only fragments with nonzero offset.
>     >     not_later Matches non-fragmented packets and fragments with zero 
> offset.
>     >
>     > When i test, setting an ip_frag match to
>     >     0x00=no
>     >     0x01=first
>     >     0x02=<error>
>     >     0x03=later
>     >     should there be enums in nicira_ext.py to define these values?
>     >
>     > if so, i can submit a patch, but also need to know correct values for 
> the other two match rules('yes' and 'not_later').
> 
>     Great! Yes, please!
> 
>     The value and mask for "ip_frag" match field seems to be defined at the 
> following.
>       
> https://github.com/openvswitch/ovs/blob/master/include/openvswitch/flow.h#L49-L52
>       
> https://github.com/openvswitch/ovs/blob/master/lib/meta-flow.c#L2199-L2211
> 
>     According to the above, I guess the constants should be like:
> 
>     FLOW_NW_FRAG_ANY = 1 << 0    // Set for any IP frag.
>     FLOW_NW_FRAG_LATER = 1 << 1  // Set for IP frag with nonzero offset.
>     FLOW_NW_FRAG_MASK = FLOW_NW_FRAG_ANY | FLOW_NW_FRAG_LATER
> 
>     // legend: (value, mask)
>     NXM_IP_FRAG_NO = (0, FLOW_NW_FRAG_MASK))
>     NXM_IP_FRAG_FIRST = (FLOW_NW_FRAG_ANY, FLOW_NW_FRAG_MASK)
>     NXM_IP_FRAG_LATER = (FLOW_NW_FRAG_MASK, FLOW_NW_FRAG_MASK)
>     ...(snip)
> 
> 
>     Thanks,
>     Iwase
> 
> 
>     >
>     >
>     >
>     >
>     > 
> ------------------------------------------------------------------------------
>     > Check out the vibrant tech community on one of the world's most
>     > engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>     >
>     >
>     >
>     > _______________________________________________
>     > Ryu-devel mailing list
>     > [email protected] <mailto:[email protected]>
>     > https://lists.sourceforge.net/lists/listinfo/ryu-devel
>     >
> 
> 
> 
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> 
> 
> 
> _______________________________________________
> Ryu-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/ryu-devel
> 

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to