-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
sys: net: add netdev device driver using dev_eth low-level ethernet driver API #2776
Conversation
(the test will not print any packets if pktdump's priority is not raised. see #2774) |
c4df596
to
ac2ddf4
Compare
fixed travis unhappyness, rebased |
Hm, I am not sure if I can help here a lot. Have some trouble testing this.
Is this setup generally correct, what is missing there? |
Mostly.
To test pinging,
|
I've added a patch that makes Linux/RIOT tap MAC addresses different. |
Ok thx, hope I will find time to test this later. |
a7ccdc9
to
03cd524
Compare
rebased. |
I can´t set the ipv6 addr using ifconfig. Is there an other dependency that enables setting the IP address using ifconfig via shell interface? |
@jremmert-phytec-iot yes, #2581. Sorry, I seem to have missed that in my original mail. |
@authmillenon guess you meant #2582? But even with #2582 merged I am not able to set an ip address. I get the error: @OlegHahm My time to work on this and get used to it is limited. Maybe it would be more effective to assign someone else on this PR. Don´t want to delay the review process. |
@jremmert-phytec-iot, as always there is no obligation to review a PR. An assignee can always decline and re-assign the PR. Feel free to chose another assignee if you don't have time to work on this. |
Needs rebase |
@authmillenon, would you take over the assignment for this PR? Or is there someone else, that wants to take over the assignment? I haven´t the time to dig deeper into it, sry. Also I have no privileges for a re-assignment. |
I think I can do this. |
return -EBADMSG; | ||
} | ||
|
||
hdr->type = byteorder_htons(ng_nettype_to_ethertype(pkt->next->type)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice to have: add NG_ETHERTYPE_RAW == 0xffff
if hdr->type == 0
. Otherwise Wireshark shows garbage. Alternatively you can fix ng_nettype_to_ethertype()
if this is desired in any case.
Please rebase. |
f9bbad0
to
e85efd2
Compare
Now that #2776 is merged:
|
I just tried this out, doing the following: RIOT:
Linux:
Then I started the
Where should I enable debug output? |
What is this line for? It shouldn't be necessary anymore. As far as I see you still do not configure the interface for forwarding: sudo sysctl -w net.ipv6.conf.all.forwarding=1 I think this is not enough, but I'm not knowledgable enough in Linux router configuration to say this for sure. Maybe this (Gentoo-centric) link helps: https://wiki.gentoo.org/wiki/IPv6_router_guide |
Just testing this PR for now. Wanted to see if the pinging works when I add it to the neighbor cache manually, and then test without adding it. And currently ping doesn't work for me :( |
But to the link-local address does, right? |
Sorry… I somehow thought I was commenting in #3049 ^^" |
But regardless… ping to link-local should work. |
e85efd2
to
eee6de7
Compare
|
Can you squash the eee6de7 into 8dda277, please? |
eee6de7
to
3a7820c
Compare
👍 |
ACK, this PR is well tested for my part. |
@authmillenon yup. @x3ro I just tried again. I added these to the tests Makefile: USEMODULE += ng_ipv6_default USEMODULE += ng_ipv6_ext USEMODULE += ng_icmpv6_echo Then compiled and started the test using # sudo bin/native/driver_netdev_eth.elf tap0 Then added a ll address in riot: > ifconfig 5 add fe80::1234/64 Then configured the linux-side: # sudo ip link set up dev tap0 Then ping: [kaspar@localhost riot.7]$ ping6 fe80::1234%tap0 PING fe80::1234%tap0(fe80::1234) 56 data bytes 64 bytes from fe80::1234: icmp_seq=1 ttl=64 time=1.01 ms ^C --- fe80::1234%tap0 ping statistics --- 1 packets transmitted, 1 received, 0% packet loss, time 0ms rtt min/avg/max/mdev = 1.015/1.015/1.015/0.000 ms [kaspar@localhost riot.7]$ |
@authmillenon Should we just merge this? ;) |
perfect. Go! |
sys: net: add netdev device driver using dev_eth low-level ethernet driver API
Ermmm… I would have been comfortable waiting for travis |
Based on #2558. Depends on #2766. Obsoletes #2770.
This PR makes any ethernet device that implements #2766 available for the new network stack.