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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 09 Apr 2009 11:18:14 +0100
From:	Jack Stone <jwjstone@...tmail.fm>
To:	linux-kernel@...r.kernel.org
CC:	jeff@...zik.org, kernel-janitors@...r.kernel.org, perex@...ex.cz
Subject: Re: [PATCH 37/56] oss: Remove void casts

[Added maintainer CC]
Jack Stone wrote:
> Remove uneeded void casts
>
> Signed-Off-By: Jack Stone <jwjstone@...tmail.fm>
> ---
>  sound/oss/msnd.c      |    2 +-
>  sound/oss/pss.c       |    6 +++---
>  sound/oss/sequencer.c |    4 ++--
>  sound/oss/sscape.c    |    2 +-
>  4 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/sound/oss/msnd.c b/sound/oss/msnd.c
> index e4282d9..21eb6dc 100644
> --- a/sound/oss/msnd.c
> +++ b/sound/oss/msnd.c
> @@ -100,7 +100,7 @@ void msnd_fifo_free(msnd_fifo *f)
>  int msnd_fifo_alloc(msnd_fifo *f, size_t n)
>  {
>  	msnd_fifo_free(f);
> -	f->data = (char *)vmalloc(n);
> +	f->data = vmalloc(n);
>  	f->n = n;
>  	f->tail = 0;
>  	f->head = 0;
> diff --git a/sound/oss/pss.c b/sound/oss/pss.c
> index 83f5ee2..82f4d5a 100644
> --- a/sound/oss/pss.c
> +++ b/sound/oss/pss.c
> @@ -859,7 +859,7 @@ static int pss_coproc_ioctl(void *dev_info, unsigned int cmd, void __user *arg,
>  			return 0;
>  
>  		case SNDCTL_COPR_LOAD:
> -			buf = (copr_buffer *) vmalloc(sizeof(copr_buffer));
> +			buf = vmalloc(sizeof(copr_buffer));
>  			if (buf == NULL)
>  				return -ENOSPC;
>  			if (copy_from_user(buf, arg, sizeof(copr_buffer))) {
> @@ -871,7 +871,7 @@ static int pss_coproc_ioctl(void *dev_info, unsigned int cmd, void __user *arg,
>  			return err;
>  		
>  		case SNDCTL_COPR_SENDMSG:
> -			mbuf = (copr_msg *)vmalloc(sizeof(copr_msg));
> +			mbuf = vmalloc(sizeof(copr_msg));
>  			if (mbuf == NULL)
>  				return -ENOSPC;
>  			if (copy_from_user(mbuf, arg, sizeof(copr_msg))) {
> @@ -895,7 +895,7 @@ static int pss_coproc_ioctl(void *dev_info, unsigned int cmd, void __user *arg,
>  
>  		case SNDCTL_COPR_RCVMSG:
>  			err = 0;
> -			mbuf = (copr_msg *)vmalloc(sizeof(copr_msg));
> +			mbuf = vmalloc(sizeof(copr_msg));
>  			if (mbuf == NULL)
>  				return -ENOSPC;
>  			data = (unsigned short *)mbuf->data;
> diff --git a/sound/oss/sequencer.c b/sound/oss/sequencer.c
> index c798746..31c01ba 100644
> --- a/sound/oss/sequencer.c
> +++ b/sound/oss/sequencer.c
> @@ -1648,13 +1648,13 @@ void sequencer_init(void)
>  {
>  	if (sequencer_ok)
>  		return;
> -	queue = (unsigned char *)vmalloc(SEQ_MAX_QUEUE * EV_SZ);
> +	queue = vmalloc(SEQ_MAX_QUEUE * EV_SZ);
>  	if (queue == NULL)
>  	{
>  		printk(KERN_ERR "sequencer: Can't allocate memory for sequencer output queue\n");
>  		return;
>  	}
> -	iqueue = (unsigned char *)vmalloc(SEQ_MAX_QUEUE * IEV_SZ);
> +	iqueue = vmalloc(SEQ_MAX_QUEUE * IEV_SZ);
>  	if (iqueue == NULL)
>  	{
>  		printk(KERN_ERR "sequencer: Can't allocate memory for sequencer input queue\n");
> diff --git a/sound/oss/sscape.c b/sound/oss/sscape.c
> index 30c36d1..9d6b9b0 100644
> --- a/sound/oss/sscape.c
> +++ b/sound/oss/sscape.c
> @@ -573,7 +573,7 @@ static int sscape_coproc_ioctl(void *dev_info, unsigned int cmd, void __user *ar
>  			return 0;
>  
>  		case SNDCTL_COPR_LOAD:
> -			buf = (copr_buffer *) vmalloc(sizeof(copr_buffer));
> +			buf = vmalloc(sizeof(copr_buffer));
>  			if (buf == NULL)
>  				return -ENOSPC;
>  			if (copy_from_user(buf, arg, sizeof(copr_buffer))) 
>   

--
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ