lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Tue, 3 Feb 2015 15:48:25 -0800 From: Greg Kroah-Hartman <gregkh@...uxfoundation.org> To: "Michael S. Tsirkin" <mst@...hat.com> Cc: linux-kernel@...r.kernel.org, Amit Shah <amit.shah@...hat.com>, Arnd Bergmann <arnd@...db.de>, virtualization@...ts.linux-foundation.org Subject: Re: [PATCH] virtio_console: fix sparse warnings On Mon, Dec 01, 2014 at 01:35:57PM +0200, Michael S. Tsirkin wrote: > CHECK drivers/char/virtio_console.c > drivers/char/virtio_console.c:687:36: warning: incorrect type in > argument 1 (different address spaces) > drivers/char/virtio_console.c:687:36: expected void [noderef] > <asn:1>*to > drivers/char/virtio_console.c:687:36: got char *out_buf > drivers/char/virtio_console.c:790:35: warning: incorrect type in > argument 2 (different address spaces) > drivers/char/virtio_console.c:790:35: expected char *out_buf > drivers/char/virtio_console.c:790:35: got char [noderef] > <asn:1>*ubuf > > fill_readbuf is reused with both kernel and userspace pointers, > depending on value of to_user flag. That's horrid, don't do that. Have two different functions for this type of thing, otherwise you defeat the whole purpose of trying to track __user pointers. thanks, greg k-h -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists