summaryrefslogtreecommitdiff
path: root/vlan.h
blob: b58d1a26f20e224d0a6a2960f140118ccf643bf9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#ifndef VLAN_H
#define VLAN_H

#include <stdbool.h>
#include <inttypes.h>

static inline uint16_t vlan_tci2prio(uint16_t tci)
{
	return (tci & 0xe000) >> 13;
}

static inline uint16_t vlan_tci2cfi(uint16_t tci)
{
	return (tci & 0x1000) >> 12;
}

static inline uint16_t vlan_tci2vid(uint16_t tci)
{
	return tci & 0x0fff;
}

#endif
ss='ctrl'>
authorViresh Kumar <viresh.kumar@linaro.org>2016-08-11 13:27:24 -0700
committerGreg Kroah-Hartman <gregkh@google.com>2016-08-12 17:38:19 +0200
commit0675363ac7ffe27a25bf237ce2bf1e084637a3a0 (patch)
tree73f0f8f32533915fda71f9afeb25fe4ef2ab486e /drivers/staging
parentb2abeaa10d5711e7730bb07120dd60ae27d7b930 (diff)
greybus: firmware: s/should/must
Replace 'should' with 'must' to clear the expectation a bit more. Reported-by: Alex Elder <alex.elder@linaro.org> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging')