Skip to content

Commit 36c269c

Browse files
gowthamabjhedberg
authored andcommitted
Bluetooth: Remove dead code
Variable 'controller' is assigned a value that is never used. Identified by cppcheck tool. Signed-off-by: Gowtham Anandha Babu <gowtham.ab@samsung.com> Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
1 parent 5ced246 commit 36c269c

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

‎net/bluetooth/cmtp/capi.c‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -253,8 +253,6 @@ static void cmtp_recv_interopmsg(struct cmtp_session *session, struct sk_buff *s
253253
if (skb->len < CAPI_MSG_BASELEN + 15)
254254
break;
255255

256-
controller = CAPIMSG_U32(skb->data, CAPI_MSG_BASELEN + 10);
257-
258256
if (!info && ctrl) {
259257
int len = min_t(uint, CAPI_MANUFACTURER_LEN,
260258
skb->data[CAPI_MSG_BASELEN + 14]);
@@ -270,8 +268,6 @@ static void cmtp_recv_interopmsg(struct cmtp_session *session, struct sk_buff *s
270268
if (skb->len < CAPI_MSG_BASELEN + 32)
271269
break;
272270

273-
controller = CAPIMSG_U32(skb->data, CAPI_MSG_BASELEN + 12);
274-
275271
if (!info && ctrl) {
276272
ctrl->version.majorversion = CAPIMSG_U32(skb->data, CAPI_MSG_BASELEN + 16);
277273
ctrl->version.minorversion = CAPIMSG_U32(skb->data, CAPI_MSG_BASELEN + 20);
@@ -285,8 +281,6 @@ static void cmtp_recv_interopmsg(struct cmtp_session *session, struct sk_buff *s
285281
if (skb->len < CAPI_MSG_BASELEN + 17)
286282
break;
287283

288-
controller = CAPIMSG_U32(skb->data, CAPI_MSG_BASELEN + 12);
289-
290284
if (!info && ctrl) {
291285
int len = min_t(uint, CAPI_SERIAL_LEN,
292286
skb->data[CAPI_MSG_BASELEN + 16]);

0 commit comments

Comments
 (0)