mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* Question about net subsystem
@ 2010-07-22  1:21 zhanglx
  2010-07-23  8:03 ` Américo Wang
  0 siblings, 1 reply; 3+ messages in thread
From: zhanglx @ 2010-07-22  1:21 UTC (permalink / raw)
  To: zhanglx, linux-kernel

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset="gb2312", Size: 622 bytes --]

hello,

I have some questions about net subsystem.

Does the kernel code store the IP address of local machine, in which variable?

If there are two net cards, then there will be two IP and MAC address, how will the kernel store them? When there are two net cards, which card will the PC use to connect to net.

Does the webbrowser such as Firefox also use the series of functions( sock(), connect(), send(),receive()...) to connect to internet?

Thanks,
zhanglxÿôèº{.nÇ+‰·Ÿ®‰­†+%ŠËÿ±éݶ\x17¥Šwÿº{.nÇ+‰·¥Š{±þG«éÿŠ{ayº\x1dʇڙë,j\a­¢f£¢·hšïêÿ‘êçz_è®\x03(­éšŽŠÝ¢j"ú\x1a¶^[m§ÿÿ¾\a«þG«éÿ¢¸?™¨è­Ú&£ø§~á¶iO•æ¬z·švØ^\x14\x04\x1a¶^[m§ÿÿÃ\fÿ¶ìÿ¢¸?–I¥

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Question about net subsystem
  2010-07-22  1:21 Question about net subsystem zhanglx
@ 2010-07-23  8:03 ` Américo Wang
  0 siblings, 0 replies; 3+ messages in thread
From: Américo Wang @ 2010-07-23  8:03 UTC (permalink / raw)
  To: zhanglx; +Cc: linux-kernel

On Thu, Jul 22, 2010 at 09:21:30AM +0800, zhanglx wrote:
>hello,
>
>I have some questions about net subsystem.
>
>Does the kernel code store the IP address of local machine, in which variable?


Yes, it is in a per-interface struct, you must be interested in how
SIOCGIFADDR is handled.

>
>If there are two net cards, then there will be two IP and MAC address, how will the kernel store them? When there are two net cards, which card will the PC use to connect to net.
>


This depends on your route table. :)


>Does the webbrowser such as Firefox also use the series of functions( sock(), connect(), send(),receive()...) to connect to internet?
>

Sure.

Hope this helps.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Question about net subsystem
@ 2010-07-23  7:39 zhanglx
  0 siblings, 0 replies; 3+ messages in thread
From: zhanglx @ 2010-07-23  7:39 UTC (permalink / raw)
  To: zhanglx, linux-kernel

There is a doc of LinuxIPNetworking on kernelnewbies.org. It describes 
networking in detail.

thanks,
zhanglx
----- Original Message ----- 
From: "zhanglx" <zhanglx@semico.com.cn>
To: "zhanglx" <zhanglx@semico.com.cn>; <linux-kernel@vger.kernel.org>
Sent: Thursday, July 22, 2010 9:21 AM
Subject: Question about net subsystem


> hello,
>
> I have some questions about net subsystem.
>
> Does the kernel code store the IP address of local machine, in which 
> variable?
>
> If there are two net cards, then there will be two IP and MAC address, how 
> will the kernel store them? When there are two net cards, which card will 
> the PC use to connect to net.
>
> Does the webbrowser such as Firefox also use the series of functions( 
> sock(), connect(), send(),receive()...) to connect to internet?
>
> Thanks,
> zhanglx 



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2010-07-23  7:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-22  1:21 Question about net subsystem zhanglx
2010-07-23  8:03 ` Américo Wang
2010-07-23  7:39 zhanglx

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome