How to activate a network interface?

What are the steps between "ifconfig eth0 UP" and "net_device->open"?

ifconfig eth0 UP =>

ioctl(skfd, SIOCSIFFLAGS, &ifr) (ifr.ifr_flags = IFF_UP | IFF_RUNNING) =>

????? => what are these steps?

net_device->open

Thanks!

Is that a shell script? Some of those lines look like regular unix commands from a shell but not all. If it's CLI stuff, what OS? If not, what language?