Adds sys/class/net devices to linsysfs. Only two interfaces are created eth0 and lo and they expose the following properties:
address, addr_len, flags, ifindex, mty, tx_queue_len and type.
Details
Mount linsysfs in a jail or in the host system and check if devices are created under sys/class/net and if properties are available.
Diff Detail
- Repository
- rS FreeBSD src repository - subversion
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Thanks, I will try to take a detailed look at this soon. For future changes, and if you have reason to upload a new diff to this review, please upload with full context as described in https://wiki.freebsd.org/action/show/Phabricator
style (9)
sys/compat/linsysfs/linsysfs.c | ||
---|---|---|
125 ↗ | (On Diff #55321) | tab until }? |
141 ↗ | (On Diff #55321) | extra line |
163 ↗ | (On Diff #55321) | remove '\n' |
165 ↗ | (On Diff #55321) | whitespace |
169 ↗ | (On Diff #55321) | add '\n' |
187 ↗ | (On Diff #55321) | same |
200 ↗ | (On Diff #55321) | same |
235 ↗ | (On Diff #55321) | whitespace in function, below too |
Hi,
The only reason is that two devices are the minimum needed to expose to applications that use sys/class/net data.
For future updates (to this review, if any, or other reviews) please include context e.g. git diff -U9999
sys/compat/linsysfs/linsysfs.c | ||
---|---|---|
268 ↗ | (On Diff #55423) | btw, why lo instead of lo0? |
sys/compat/linsysfs/linsysfs.c | ||
---|---|---|
268 ↗ | (On Diff #55423) | It's Linux's name for the loopback interface (not lo0). |
head/sys/compat/linsysfs/linsysfs.c | ||
---|---|---|
5 | Ar you really need this line? As I rewrote most of the patch? ) |