#6211 BLOC Future : patch for support of per packet mesh ttl

Zarro Boogs per Child bugtracker at laptop.org
Fri Feb 15 11:03:06 EST 2008


#6211: patch for support of per packet mesh ttl
--------------------------+-------------------------------------------------
  Reporter:  mbletsas     |       Owner:  dwmw2                         
      Type:  enhancement  |      Status:  new                           
  Priority:  blocker      |   Milestone:  Future Release                
 Component:  wireless     |     Version:                                
Resolution:               |    Keywords:  libertas, ttl, mesh, Update.1?
  Verified:  0            |    Blocking:                                
 Blockedby:               |  
--------------------------+-------------------------------------------------

Comment(by dilinger):

 Replying to [comment:10 jcardona]:
 > Replying to [comment:4 cscott]:
 > > Has this patch ever been tested?
 >
 [...]
 > > This patch, however, is certainly not ready to apply.
 >
 > Agreed.  But [https://cozybit1.dnsalias.org/~javier/patches/0001
 -libertas-Per-socket-mesh-ttl-via-setsockopt.patch this one] is.  As soon
 as we finish testing the new version we'll send that to libertas-dev.

 Hm, tx_packet_location needs to go away..

 Anyways, two minor nits:

 {{{
 +               if (mesh_opts.get_sock_ttl) {
 +                       unsigned char ttl =
 (*mesh_opts.get_sock_ttl)(skb->sk);
 +                       if (ttl) {
 +                               tx_data[0] = 0; /* reserved */
 +                               tx_data[1] = 0; /* reserved */
 +                               tx_data[2] =
 (*mesh_opts.get_sock_ttl)(skb->sk);
 }}}

 Is there any reason why you're calling get_sock_ttl twice?

 {{{
 +int libertas_register_mesh_opts(struct mesh_options *opts)
 +{
 +       mesh_opts.get_sock_ttl = opts->get_sock_ttl;
 +       return 0;
 +}
 +EXPORT_SYMBOL_GPL(libertas_register_mesh_opts);
 +
 +int libertas_unregister_mesh_opts(struct mesh_options *opts)
 +{
 +       mesh_opts.get_sock_ttl = NULL;
 +       return 0;
 +}
 }}}

 If you're going to ignore their return values anyways, please return void.

-- 
Ticket URL: <http://dev.laptop.org/ticket/6211#comment:13>
One Laptop Per Child <http://dev.laptop.org>
OLPC bug tracking system



More information about the Bugs mailing list