Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 7721
b: refs/heads/master
c: deb92b7
h: refs/heads/master
i:
  7719: e359075
v: v3
  • Loading branch information
Douglas Gilbert authored and James Bottomley committed Sep 5, 2005
1 parent f955309 commit 4e48be4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 07542b832309b93a2741cd162a391ab909f66438
refs/heads/master: deb92b7ee98e8e580cafaa63bd1edbe6646877bc
8 changes: 4 additions & 4 deletions trunk/drivers/scsi/sg.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ static int sg_version_num = 30533; /* 2 digits for each component */

#ifdef CONFIG_SCSI_PROC_FS
#include <linux/proc_fs.h>
static char *sg_version_date = "20050328";
static char *sg_version_date = "20050901";

static int sg_proc_init(void);
static void sg_proc_cleanup(void);
Expand Down Expand Up @@ -1794,12 +1794,12 @@ st_map_user_pages(struct scatterlist *sgl, const unsigned int max_pages,
unsigned long uaddr, size_t count, int rw,
unsigned long max_pfn)
{
unsigned long end = (uaddr + count + PAGE_SIZE - 1) >> PAGE_SHIFT;
unsigned long start = uaddr >> PAGE_SHIFT;
const int nr_pages = end - start;
int res, i, j;
unsigned int nr_pages;
struct page **pages;

nr_pages = ((uaddr & ~PAGE_MASK) + count + ~PAGE_MASK) >> PAGE_SHIFT;

/* User attempted Overflow! */
if ((uaddr + count) < uaddr)
return -EINVAL;
Expand Down

0 comments on commit 4e48be4

Please sign in to comment.