From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Marcel Holtmann <marcel@holtmann.org>,
Gustavo Padovan <gustavo@padovan.org>,
Johan Hedberg <johan.hedberg@gmail.com>,
"David S. Miller" <davem@davemloft.net>
Cc: linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
Loic Poulain <loic.poulain@linaro.org>
Subject: [PATCH 1/2] Bluetooth: make baswap src const
Date: Fri, 1 Sep 2017 13:41:17 -0700 [thread overview]
Message-ID: <20170901204118.17123-2-bjorn.andersson@linaro.org> (raw)
In-Reply-To: <20170901204118.17123-1-bjorn.andersson@linaro.org>
From: Loic Poulain <loic.poulain@linaro.org>
Signed-off-by: Loic Poulain <loic.poulain@linaro.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
---
include/net/bluetooth/bluetooth.h | 2 +-
net/bluetooth/lib.c | 4 ++--
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/include/net/bluetooth/bluetooth.h b/include/net/bluetooth/bluetooth.h
index 01487192f628..020142bb9735 100644
--- a/include/net/bluetooth/bluetooth.h
+++ b/include/net/bluetooth/bluetooth.h
@@ -233,7 +233,7 @@ static inline void bacpy(bdaddr_t *dst, const bdaddr_t *src)
memcpy(dst, src, sizeof(bdaddr_t));
}
-void baswap(bdaddr_t *dst, bdaddr_t *src);
+void baswap(bdaddr_t *dst, const bdaddr_t *src);
/* Common socket structures and functions */
diff --git a/net/bluetooth/lib.c b/net/bluetooth/lib.c
index aa4cf64e32a6..6048cc07568b 100644
--- a/net/bluetooth/lib.c
+++ b/net/bluetooth/lib.c
@@ -30,10 +30,10 @@
#include <net/bluetooth/bluetooth.h>
-void baswap(bdaddr_t *dst, bdaddr_t *src)
+void baswap(bdaddr_t *dst, const bdaddr_t *src)
{
+ const unsigned char *s = (const unsigned char *)src;
unsigned char *d = (unsigned char *) dst;
- unsigned char *s = (unsigned char *) src;
unsigned int i;
for (i = 0; i < 6; i++)
--
2.12.0
next prev parent reply other threads:[~2017-09-01 20:41 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-01 20:41 [PATCH 0/2] btqcomsmd: Allow specifying board mac address Bjorn Andersson
2017-09-01 20:41 ` Bjorn Andersson [this message]
2017-09-01 20:51 ` [PATCH 1/2] Bluetooth: make baswap src const Marcel Holtmann
2017-09-01 20:41 ` [PATCH 2/2] Bluetooth: btqcomsmd: BD address setup Bjorn Andersson
2017-09-01 20:47 ` Marcel Holtmann
2017-09-01 21:26 ` Rob Herring
2017-09-02 6:12 ` Marcel Holtmann
2017-09-03 21:10 ` Bjorn Andersson
2017-09-01 22:15 ` Bjorn Andersson
2017-09-02 6:38 ` Marcel Holtmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170901204118.17123-2-bjorn.andersson@linaro.org \
--to=bjorn.andersson@linaro.org \
--cc=davem@davemloft.net \
--cc=gustavo@padovan.org \
--cc=johan.hedberg@gmail.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-bluetooth@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=loic.poulain@linaro.org \
--cc=marcel@holtmann.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).