[PATCH 1/1] net: add multiple nameserver support

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Sat Sep 22 16:16:37 EDT 2012


On 21:25 Sat 22 Sep     , Christoph Fritz wrote:
> On Sat, 2012-09-22 at 20:27 +0200, Jean-Christophe PLAGNIOL-VILLARD
> wrote:
> 
> > +
> >  static int do_host(int argc, char *argv[])
> >  {
> >  	IPaddr_t ip;
> > diff --git a/net/net.c b/net/net.c
> > index 3ac098f..edadf51 100644
> > --- a/net/net.c
> > +++ b/net/net.c
> > @@ -677,7 +677,8 @@ static int net_init(void)
> >  		NetRxPackets[i] = net_alloc_packet();
> >  
> >  	register_device(&net_device);
> > -	dev_add_param(&net_device, "nameserver", NULL, NULL, 0);
> > +	dev_add_param(&net_device, "nameserver0", NULL, NULL, 0);
> > +	dev_add_param(&net_device, "nameserver1", NULL, NULL, 0);
> 
> What do you think about a function that checks if nameserver0/1 is
> really an IP, like this:
why not I've not strong felling about it

Best Regards,
J.



More information about the barebox mailing list