aboutsummaryrefslogtreecommitdiffstats
path: root/net/caif/cfsrvl.c
diff options
context:
space:
mode:
authorDmitry Tarnyagin <dmitry.tarnyagin@stericsson.com>2012-04-12 04:27:24 -0400
committerDavid S. Miller <davem@davemloft.net>2012-04-13 11:37:36 -0400
commit447648128ec22e294604674ffe1064aa3ec3b767 (patch)
tree1dfb671203f989a8612704674bbe59c78cf27109 /net/caif/cfsrvl.c
parente65ac4d54546b7d7514a9e8be1484c758f2b7ba3 (diff)
caif: set traffic class for caif packets
Set traffic class for CAIF packets, based on socket priority, CAIF protocol type, or type of message. Traffic class mapping for different packet types: - control: TC_PRIO_CONTROL; - flow control: TC_PRIO_CONTROL; - at: TC_PRIO_CONTROL; - rfm: TC_PRIO_INTERACTIVE_BULK; - other sockets: equals to socket's TC; - network data: no change. Signed-off-by: Dmitry Tarnyagin <dmitry.tarnyagin@stericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/caif/cfsrvl.c')
-rw-r--r--net/caif/cfsrvl.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/caif/cfsrvl.c b/net/caif/cfsrvl.c
index 4aa33d4496b6..dd485f6128e8 100644
--- a/net/caif/cfsrvl.c
+++ b/net/caif/cfsrvl.c
@@ -11,6 +11,7 @@
11#include <linux/errno.h> 11#include <linux/errno.h>
12#include <linux/slab.h> 12#include <linux/slab.h>
13#include <linux/module.h> 13#include <linux/module.h>
14#include <linux/pkt_sched.h>
14#include <net/caif/caif_layer.h> 15#include <net/caif/caif_layer.h>
15#include <net/caif/cfsrvl.h> 16#include <net/caif/cfsrvl.h>
16#include <net/caif/cfpkt.h> 17#include <net/caif/cfpkt.h>
@@ -120,6 +121,7 @@ static int cfservl_modemcmd(struct cflayer *layr, enum caif_modemcmd ctrl)
120 info->channel_id = service->layer.id; 121 info->channel_id = service->layer.id;
121 info->hdr_len = 1; 122 info->hdr_len = 1;
122 info->dev_info = &service->dev_info; 123 info->dev_info = &service->dev_info;
124 cfpkt_set_prio(pkt, TC_PRIO_CONTROL);
123 return layr->dn->transmit(layr->dn, pkt); 125 return layr->dn->transmit(layr->dn, pkt);
124 } 126 }
125 case CAIF_MODEMCMD_FLOW_OFF_REQ: 127 case CAIF_MODEMCMD_FLOW_OFF_REQ:
@@ -140,6 +142,7 @@ static int cfservl_modemcmd(struct cflayer *layr, enum caif_modemcmd ctrl)
140 info->channel_id = service->layer.id; 142 info->channel_id = service->layer.id;
141 info->hdr_len = 1; 143 info->hdr_len = 1;
142 info->dev_info = &service->dev_info; 144 info->dev_info = &service->dev_info;
145 cfpkt_set_prio(pkt, TC_PRIO_CONTROL);
143 return layr->dn->transmit(layr->dn, pkt); 146 return layr->dn->transmit(layr->dn, pkt);
144 } 147 }
145 default: 148 default: