strcut casts unsigned long

hong zhang <[email protected]>
Newsgroups org.kernel.vger.linux-c-programming
Message-ID <[email protected]>
List,

I have C question on skbuff.h.
skb->_skb_dst is defined as unsigned long and dst_entry is struct.

Why strct dst_entry casts unsigned long skb->_skb_dst?

See below

static inline struct dst_entry *skb_dst(const struct sk_buff *skb)
{
	return (struct dst_entry *)skb->_skb_dst;
}

Appreciate any answer!

--henry
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.