mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-29 13:53:33 +00:00
net: pim: add a helper to check for IPv4 all pim routers address
Signed-off-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
556d299fcb
commit
20bb6ce987
1 changed files with 6 additions and 0 deletions
|
@ -57,4 +57,10 @@ static inline u8 pim_hdr_type(const struct pimhdr *pimhdr)
|
|||
{
|
||||
return pimhdr->type & 0xf;
|
||||
}
|
||||
|
||||
/* check if the address is 224.0.0.13, RFC7761 sec 4.3.1 */
|
||||
static inline bool pim_ipv4_all_pim_routers(__be32 addr)
|
||||
{
|
||||
return addr == htonl(0xE000000D);
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue