New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
netdev2: rename to netdev and remove gnrc_netdev
#6610
Conversation
found and fixed minor issue (inclusion of (original) |
efca06f
to
7062100
Compare
Rebased (fun!) |
7062100
to
d1c130c
Compare
Rebased. |
With some minor hand-edits I used the following chain of commands: ```sh git rm sys/include/net/gnrc/netdev.h git grep --name-only -i netdev2 | \ xargs sed -i -e 's/^\(NETDEV\)2\(.*\)\( [("]\)/\1\2 \3/g' \ -e 's/\(netdev\)2\(.*\)\( \/\*\*<\)/\1\2 \3/I' \ -e 's/\(netdev\)2/\1/gI' git add -p git commit --amend git ls-tree --full-tree -r HEAD --name-only | \ grep "netdev2" | xargs -I'{}' dirname '{}' | uniq | \ grep "netdev2" | while read dir; do new_dir="$(echo "$dir" | sed "s/netdev2/netdev/g")" git mv -f "$dir" "$new_dir" done git commit --amend git ls-tree --full-tree -r HEAD --name-only | \ grep "netdev2" | while read file; do new_file="$(echo "$file" | sed "s/netdev2/netdev/g")" git mv -f "$file" "$new_file" done git commit --amend git grep --name-only "\<drivers_netdev_netdev\>" | \ xargs sed -i "s/\<drivers_netdev_netdev\>/drivers_netdev_api/g" git add -p git commit --amend ```
d1c130c
to
29842bb
Compare
Rebased. I would like to avoid another ;-) |
Well, it compiles... I'd say, merge once Murdock1 agrees? @miri64 how hard would it be to seperate removal of gnrc_netdev, automatic changes and the changes made by hand into seperate commits? |
By the way: would this be a good candidate to test Coccinelle use? |
+1 for merging after Murdock agrees |
Maybe. But the work is done I guess. ;) |
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.
ACK.
Yes, the work is done, but it could still be a good benchmark for the usefulness of the tool in RIOT? |
Try and let us know! |
Do we need a second ACK for this? I admit I did not look at all those 1700 changed lines. |
it would be basically doing everything all over again, since I do not remember which change I did how :-/
TBH, I totally forgot about this tool again :( Thanks for the reminder. But since there were a few handcrafted changes that might have been able automatized with a more complex tool than |
I would feel better if someone else than me would at least test, if |
Confirmed gnrc_networking is still working (tried ping). Let's go! |
@miri64 Would you mind letting devel@ know about the change? |
Not at all, will write a mail. |
@miri64 great to finally have straightened this part of the API out! |
Networking is partly broken in my 2 samr21-xpro boards since this PR was merged. When both are running the gnrc_networking example, they can ping each other only on their link local addresses. Even if they have global addresses assigned (or autoconfigured) they can't ping each other using them. This rename might have introduced issues to NDP which breaks the neighbor cache of the nodes. In another scenario, one xpro is acting as a border router (based on the gnrc_border_router example, modified to use the enc28j60 ethernet adapter instead of ethos for uplink) and the other as a node with gnrc_networking. Networking with global addresses is now broken there too. The border router can't talk to the upstream network router or the 802.15.4 nodes except using link-local addresses. |
I can't confirm the border router case (samr21-xpro with ethos ethernet). For the first case: Did you set the forwarding in the FIB as well? Auto-config won't cut that (that was the case before this PR was merged too). |
Yes I did. I've been testing the border router case, now it works again after I reverted just before this PR. |
As I said: I can't confirm (I don't have the |
I will investigate it a bit further when I have some time, it might be an issue with enc28j60 as well. Thanks for checking on your end! |
With some minor hand-edits I used the following chain of commands: