From: Syam Sidhardhan Date: Wed, 10 Oct 2012 16:39:28 +0000 (+0530) Subject: Bluetooth: Use __constant modifier for L2CAP SMP CID X-Git-Tag: v3.8-rc1~139^2~17^2~353^2~23 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d8aece2af380a251daf2351d92dd38b9edf10b84;p=platform%2Fupstream%2Fkernel-adaptation-pc.git Bluetooth: Use __constant modifier for L2CAP SMP CID Since the L2CAP_CID_SMP is constant, __constant_cpu_to_le16() is the right go here. Signed-off-by: Syam Sidhardhan Acked-by: Marcel Holtmann Signed-off-by: Gustavo Padovan --- diff --git a/net/bluetooth/smp.c b/net/bluetooth/smp.c index 8c225ef..9b54fea 100644 --- a/net/bluetooth/smp.c +++ b/net/bluetooth/smp.c @@ -165,7 +165,7 @@ static struct sk_buff *smp_build_cmd(struct l2cap_conn *conn, u8 code, lh = (struct l2cap_hdr *) skb_put(skb, L2CAP_HDR_SIZE); lh->len = cpu_to_le16(sizeof(code) + dlen); - lh->cid = cpu_to_le16(L2CAP_CID_SMP); + lh->cid = __constant_cpu_to_le16(L2CAP_CID_SMP); memcpy(skb_put(skb, sizeof(code)), &code, sizeof(code));