Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 325279
b: refs/heads/master
c: 98f4ead
h: refs/heads/master
i:
  325277: 2d1a319
  325275: 83ea1d7
  325271: 68674c8
  325263: dd1db98
  325247: 2806517
v: v3
  • Loading branch information
Aaro Koskinen authored and Greg Kroah-Hartman committed Sep 14, 2012
1 parent 32779fd commit 0abeff6
Show file tree
Hide file tree
Showing 2 changed files with 7 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: 1839c7ebd9363cc73b55ce48d4c3c6823c2fdd42
refs/heads/master: 98f4eade14b4bb077304ca16a1be45ec9c72b381
10 changes: 6 additions & 4 deletions trunk/drivers/staging/xgifb/XGI_main_26.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt

#include <linux/sizes.h>
#include <linux/module.h>

#ifdef CONFIG_MTRR
Expand Down Expand Up @@ -1470,6 +1471,9 @@ static int XGIfb_get_dram_size(struct xgifb_video_info *xgifb_info)
xgifb_reg_set(XGISR, IND_SIS_DRAM_SIZE, 0x51);

reg = xgifb_reg_get(XGISR, IND_SIS_DRAM_SIZE);
if (!reg)
return -1;

switch ((reg & XGI_DRAM_SIZE_MASK) >> 4) {
case XGI_DRAM_SIZE_1MB:
xgifb_info->video_size = 0x100000;
Expand Down Expand Up @@ -1778,10 +1782,8 @@ static int __devinit xgifb_probe(struct pci_dev *pdev,
hw_info->jChipType = xgifb_info->chip;

if (XGIfb_get_dram_size(xgifb_info)) {
dev_err(&pdev->dev,
"Fatal error: Unable to determine RAM size.\n");
ret = -ENODEV;
goto error_disable;
xgifb_info->video_size = min_t(unsigned long, video_size_max,
SZ_16M);
} else if (xgifb_info->video_size > video_size_max) {
xgifb_info->video_size = video_size_max;
}
Expand Down

0 comments on commit 0abeff6

Please sign in to comment.