dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Hellstrom <thomas@shipmail.org>
To: Joe Perches <joe@perches.com>
Cc: Jiri Kosina <trivial@kernel.org>,
	linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 10/49] drivers/gpu: Use vzalloc
Date: Fri, 05 Nov 2010 10:29:32 +0100	[thread overview]
Message-ID: <4CD3CE7C.4040407@shipmail.org> (raw)
In-Reply-To: <82d9fb31aa5f4e28acfda333331a30ef382d27b9.1288925424.git.joe@perches.com>

On 11/05/2010 04:07 AM, Joe Perches wrote:
> Signed-off-by: Joe Perches<joe@perches.com>
>    
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>

> ---
>   drivers/gpu/drm/via/via_dmablit.c |    4 ++--
>   1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/via/via_dmablit.c b/drivers/gpu/drm/via/via_dmablit.c
> index 9b5b4d9..3e038a3 100644
> --- a/drivers/gpu/drm/via/via_dmablit.c
> +++ b/drivers/gpu/drm/via/via_dmablit.c
> @@ -235,9 +235,9 @@ via_lock_all_dma_pages(drm_via_sg_info_t *vsg,  drm_via_dmablit_t *xfer)
>   	vsg->num_pages = VIA_PFN(xfer->mem_addr + (xfer->num_lines * xfer->mem_stride - 1)) -
>   		first_pfn + 1;
>
> -	if (NULL == (vsg->pages = vmalloc(sizeof(struct page *) * vsg->num_pages)))
> +	vsg->pages = vzalloc(sizeof(struct page *) * vsg->num_pages);
> +	if (NULL == vsg->pages)
>   		return -ENOMEM;
> -	memset(vsg->pages, 0, sizeof(struct page *) * vsg->num_pages);
>   	down_read(&current->mm->mmap_sem);
>   	ret = get_user_pages(current, current->mm,
>   			     (unsigned long)xfer->mem_addr,
>    

      reply	other threads:[~2010-11-05  9:29 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <alpine.DEB.2.00.1011031108260.11625@router.home>
2010-11-05  3:07 ` [PATCH 00/49] Use vzalloc not vmalloc/kmemset Joe Perches
2010-11-05  3:07   ` [PATCH 10/49] drivers/gpu: Use vzalloc Joe Perches
2010-11-05  9:29     ` Thomas Hellstrom [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4CD3CE7C.4040407@shipmail.org \
    --to=thomas@shipmail.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=trivial@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox