@@ -621,7 +642,11 @@ static int bluecard_hci_flush(struct hci
static int bluecard_hci_open(struct hci_dev *hdev)
{
- bluecard_info_t *info = (bluecard_info_t *)(hdev->driver_data);
+ bluecard_info_t *info = hci_get_drvdata(hdev);
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
unsigned int iobase = info->p_dev->resource[0]->start;
+#else
@@ -641,7 +666,11 @@ static int bluecard_hci_open(struct hci_
static int bluecard_hci_close(struct hci_dev *hdev)
{
- bluecard_info_t *info = (bluecard_info_t *)(hdev->driver_data);
+ bluecard_info_t *info = hci_get_drvdata(hdev);
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
unsigned int iobase = info->p_dev->resource[0]->start;
+#else
if (!test_and_clear_bit(HCI_RUNNING, &(hdev->flags)))
return 0;
-@@ -708,7 +737,11 @@ static int bluecard_hci_ioctl(struct hci
+@@ -703,7 +732,11 @@ static int bluecard_hci_ioctl(struct hci
static int bluecard_open(bluecard_info_t *info)
{
struct hci_dev *hdev;
unsigned char id;
-@@ -827,7 +860,11 @@ static int bluecard_open(bluecard_info_t
+@@ -819,7 +852,11 @@ static int bluecard_open(bluecard_info_t
static int bluecard_close(bluecard_info_t *info)
{
struct hci_dev *hdev = info->hdev;
if (!hdev)
-@@ -862,7 +899,18 @@ static int bluecard_probe(struct pcmcia_
+@@ -854,7 +891,18 @@ static int bluecard_probe(struct pcmcia_
info->p_dev = link;
link->priv = info;
return bluecard_config(link);
}
-@@ -882,15 +930,30 @@ static int bluecard_config(struct pcmcia
+@@ -874,15 +922,30 @@ static int bluecard_config(struct pcmcia
bluecard_info_t *info = link->priv;
int i, n;
if (i == 0)
break;
}
-@@ -898,9 +961,15 @@ static int bluecard_config(struct pcmcia
+@@ -890,9 +953,15 @@ static int bluecard_config(struct pcmcia
if (i != 0)
goto failed;
i = pcmcia_enable_device(link);
if (i != 0)
-@@ -938,7 +1007,13 @@ MODULE_DEVICE_TABLE(pcmcia, bluecard_ids
+@@ -930,7 +999,13 @@ MODULE_DEVICE_TABLE(pcmcia, bluecard_ids
static struct pcmcia_driver bluecard_driver = {
.owner = THIS_MODULE,