LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Closed Thread
  Search this Thread
Old 12-17-2013, 02:33 AM   #1
szkbsgy
LQ Newbie
 
Registered: Dec 2013
Posts: 2

Rep: Reputation: Disabled
How to get IPv6 address by function __in6_dev_get in kernel?


Following codes is ok in linux2.6, but not in linux3.0.

int ipv6_get_addr(struct net_device *dev, struct in6_addr *addr)
{
struct inet6_dev *idev;
struct inet6_ifaddr *ifp;

idev = __in6_dev_get(dev);

for(ifp=idev->addr_list; ifp; ifp=ifp0>if_next)
{
if(ifp->scope != IFA_LINK && !(ifp->flag&&IFA_F_TENTATIVE))
{
ipv6_addr_copy(addr, &ifp->addr);
break;
}
}
}

I find data struct inet6_dev and inet6_ifaddr changed. I have no idea with this, anyone can give some suggestions?
 
Old 12-17-2013, 02:39 AM   #2
druuna
LQ Veteran
 
Registered: Sep 2003
Posts: 10,532
Blog Entries: 7

Rep: Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387Reputation: 2387
Cross-posting is against the LQ rules. Please post your thread in only one forum. Posting a single thread in the most relevant forum will make it easier for members to help you and will keep the discussion in one place.

Continue in the other/original thread: https://www.linuxquestions.org/quest...el-4175488249/

Reported for closure.
 
  


Closed Thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to get IPv6 address by function __in6_dev_get in kernel? szkbsgy Linux - Kernel 0 12-18-2013 10:44 AM
How to set breakpoint to obtain address of a function in fork.c , in the kernel sourc jyteh Linux - Kernel 4 11-08-2013 04:47 AM
Kernel API to find device name from IPv6 address ? Jpradhan Linux - General 0 09-27-2010 09:02 AM
How to set IPv6 address on IPv6 router tlemons Linux - Networking 3 09-17-2007 02:25 PM
getting IPv6 address lacitpo Linux - Networking 1 03-18-2005 12:09 PM


All times are GMT -5. The time now is 12:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration