git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
patch-2_6_7-vs1_9_1_12
[linux-2.6.git]
/
drivers
/
bluetooth
/
hci_vhci.c
diff --git
a/drivers/bluetooth/hci_vhci.c
b/drivers/bluetooth/hci_vhci.c
index
871f383
..
9faa8a0
100644
(file)
--- a/
drivers/bluetooth/hci_vhci.c
+++ b/
drivers/bluetooth/hci_vhci.c
@@
-127,7
+127,7
@@
static unsigned int hci_vhci_chr_poll(struct file *file, poll_table * wait)
}
/* Get packet from user space buffer(already verified) */
}
/* Get packet from user space buffer(already verified) */
-static inline ssize_t hci_vhci_get_user(struct hci_vhci_struct *hci_vhci, const char *buf, size_t count)
+static inline ssize_t hci_vhci_get_user(struct hci_vhci_struct *hci_vhci, const char
__user
*buf, size_t count)
{
struct sk_buff *skb;
{
struct sk_buff *skb;
@@
-152,7
+152,7
@@
static inline ssize_t hci_vhci_get_user(struct hci_vhci_struct *hci_vhci, const
}
/* Write */
}
/* Write */
-static ssize_t hci_vhci_chr_write(struct file * file, const char * buf,
+static ssize_t hci_vhci_chr_write(struct file * file, const char
__user
* buf,
size_t count, loff_t *pos)
{
struct hci_vhci_struct *hci_vhci = (struct hci_vhci_struct *) file->private_data;
size_t count, loff_t *pos)
{
struct hci_vhci_struct *hci_vhci = (struct hci_vhci_struct *) file->private_data;
@@
-165,10
+165,11
@@
static ssize_t hci_vhci_chr_write(struct file * file, const char * buf,
/* Put packet to user space buffer(already verified) */
static inline ssize_t hci_vhci_put_user(struct hci_vhci_struct *hci_vhci,
/* Put packet to user space buffer(already verified) */
static inline ssize_t hci_vhci_put_user(struct hci_vhci_struct *hci_vhci,
- struct sk_buff *skb, char *buf, int count)
+ struct sk_buff *skb, char __user *buf,
+ int count)
{
int len = count, total = 0;
{
int len = count, total = 0;
- char *ptr = buf;
+ char
__user
*ptr = buf;
len = min_t(unsigned int, skb->len, len);
if (copy_to_user(ptr, skb->data, len))
len = min_t(unsigned int, skb->len, len);
if (copy_to_user(ptr, skb->data, len))
@@
-194,7
+195,7
@@
static inline ssize_t hci_vhci_put_user(struct hci_vhci_struct *hci_vhci,
}
/* Read */
}
/* Read */
-static ssize_t hci_vhci_chr_read(struct file * file, char * buf, size_t count, loff_t *pos)
+static ssize_t hci_vhci_chr_read(struct file * file, char
__user
* buf, size_t count, loff_t *pos)
{
struct hci_vhci_struct *hci_vhci = (struct hci_vhci_struct *) file->private_data;
DECLARE_WAITQUEUE(wait, current);
{
struct hci_vhci_struct *hci_vhci = (struct hci_vhci_struct *) file->private_data;
DECLARE_WAITQUEUE(wait, current);