summaryrefslogtreecommitdiff
path: root/lib/hci.c
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2013-10-07 15:32:40 -0700
committerMarcel Holtmann <marcel@holtmann.org>2013-10-07 15:32:40 -0700
commit4feaf68bf2730641adaba09c98d88d7ee5506f24 (patch)
treed8bad7e9ff054d7ca12e2a777604a00e57bd8492 /lib/hci.c
parent0ab01d55a5ab256f85aed0bb3d3ded2488d6c544 (diff)
downloadbluez-4feaf68bf2730641adaba09c98d88d7ee5506f24.tar.gz
lib: Add special functions for PAL version mapping
Diffstat (limited to 'lib/hci.c')
-rw-r--r--lib/hci.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/hci.c b/lib/hci.c
index 7a06dc5f4..6e3783671 100644
--- a/lib/hci.c
+++ b/lib/hci.c
@@ -672,6 +672,21 @@ int lmp_strtover(char *str, unsigned int *ver)
return hci_str2uint(ver_map, str, ver);
}
+static hci_map pal_map[] = {
+ { "3.0", 0x01 },
+ { NULL }
+};
+
+char *pal_vertostr(unsigned int ver)
+{
+ return hci_uint2str(pal_map, ver);
+}
+
+int pal_strtover(char *str, unsigned int *ver)
+{
+ return hci_str2uint(pal_map, str, ver);
+}
+
/* LMP features mapping */
static hci_map lmp_features_map[8][9] = {
{ /* Byte 0 */