totofugaのブログ

ネットワークとかc言語、perlの話。

2017-12-09から1日間の記事一覧

ip link経由でのドライバ追加

家にあるLinuxデバイスドライバの本のネットワークドライバのサンプルが古すぎて動かないので 4.9.57で動くようにしてついでに今風にipコマンド経由で追加できるように書き換えてみた。 最低限動くようにするところだけ移行。 #include <linux/kernel.h> #include <linux/module.h> #include <linux/netdevice.h></linux/netdevice.h></linux/module.h></linux/kernel.h>…