err = get_user_pages(current,current->mm, 
err = get_user_pages(current,current->mm, 
int videobuf_dma_init_user(struct videobuf_dmabuf *dma, int direction,			   unsigned long data, unsigned long size){	unsigned long first,last;	int err, rw = 0;	dma->direction = direction;	switch (dma->direction) {	case PCI_DMA_FROMDEVICE: rw = READ;  break;	case PCI_DMA_TODEVICE:   rw = WRITE; break;	default:                 BUG();	}	first = (data          & PAGE_MASK) >> PAGE_SHIFT;	last  = ((data+size-1) & PAGE_MASK) >> PAGE_SHIFT;	dma->offset   = data & ~PAGE_MASK;	dma->nr_pages = last-first+1;	dma->pages = kmalloc(dma->nr_pages * sizeof(struct page*),			     GFP_KERNEL);	if (NULL == dma->pages)		return -ENOMEM;	dprintk(1,"init user [0x%lx+0x%lx => %d pages]\n",		data,size,dma->nr_pages);	down_read(&current->mm->mmap_sem);        err = get_user_pages(current,current->mm,			     data & PAGE_MASK, dma->nr_pages,			     rw == READ, 1, /* force */			     dma->pages, NULL);	up_read(&current->mm->mmap_sem);	if (err != dma->nr_pages) {		dma->nr_pages = (err >= 0) ? err : 0;		dprintk(1,"get_user_pages: err=%d [%d]\n",err,dma->nr_pages);		return err < 0 ? err : -EINVAL;	}	return 0;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/4ac97914c6c35f6bf132071c718e034d0846b9f5/video-buf.c/clean/drivers/media/video/video-buf.c