Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 39759
b: refs/heads/master
c: bb579cf
h: refs/heads/master
i:
  39757: b6d0048
  39755: b6bdc16
  39751: db04d17
  39743: 7224036
v: v3
  • Loading branch information
Eric Sesterhenn authored and Paul Mackerras committed Oct 16, 2006
1 parent 9600653 commit 56b471c
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 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: ee4ea82c07fa8aa46037962ec3e8b40c5144b5eb
refs/heads/master: bb579cf1d413b930be0241987b848e0f0c1b292f
4 changes: 2 additions & 2 deletions trunk/arch/ppc/platforms/mpc8272ads_setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ static void __init mpc8272ads_fixup_enet_pdata(struct platform_device *pdev,
bd_t* bi = (void*)__res;
int fs_no = fsid_fcc1+pdev->id-1;

if(fs_no > ARRAY_SIZE(mpc82xx_enet_pdata)) {
if(fs_no >= ARRAY_SIZE(mpc82xx_enet_pdata)) {
return;
}

Expand All @@ -222,7 +222,7 @@ static void mpc8272ads_fixup_uart_pdata(struct platform_device *pdev,
int id = fs_uart_id_scc2fsid(idx);

/* no need to alter anything if console */
if ((id <= num) && (!pdev->dev.platform_data)) {
if ((id < num) && (!pdev->dev.platform_data)) {
pinfo = &mpc8272_uart_pdata[id];
pinfo->uart_clk = bd->bi_intfreq;
pdev->dev.platform_data = pinfo;
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/ppc/platforms/mpc866ads_setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ static void mpc866ads_fixup_enet_pdata(struct platform_device *pdev, int fs_no)
/* Get pointer to Communication Processor */
cp = cpmp;

if(fs_no > ARRAY_SIZE(mpc8xx_enet_pdata)) {
if(fs_no >= ARRAY_SIZE(mpc8xx_enet_pdata)) {
printk(KERN_ERR"No network-suitable #%d device on bus", fs_no);
return;
}
Expand Down Expand Up @@ -305,7 +305,7 @@ static void __init mpc866ads_fixup_uart_pdata(struct platform_device *pdev,
int id = fs_uart_id_smc2fsid(idx);

/* no need to alter anything if console */
if ((id <= num) && (!pdev->dev.platform_data)) {
if ((id < num) && (!pdev->dev.platform_data)) {
pinfo = &mpc866_uart_pdata[id];
pinfo->uart_clk = bd->bi_intfreq;
pdev->dev.platform_data = pinfo;
Expand Down
4 changes: 2 additions & 2 deletions trunk/arch/ppc/platforms/mpc885ads_setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ static void mpc885ads_fixup_enet_pdata(struct platform_device *pdev, int fs_no)
char *e;
int i;

if(fs_no > ARRAY_SIZE(mpc8xx_enet_pdata)) {
if(fs_no >= ARRAY_SIZE(mpc8xx_enet_pdata)) {
printk(KERN_ERR"No network-suitable #%d device on bus", fs_no);
return;
}
Expand Down Expand Up @@ -371,7 +371,7 @@ static void __init mpc885ads_fixup_uart_pdata(struct platform_device *pdev,
int id = fs_uart_id_smc2fsid(idx);

/* no need to alter anything if console */
if ((id <= num) && (!pdev->dev.platform_data)) {
if ((id < num) && (!pdev->dev.platform_data)) {
pinfo = &mpc885_uart_pdata[id];
pinfo->uart_clk = bd->bi_intfreq;
pdev->dev.platform_data = pinfo;
Expand Down

0 comments on commit 56b471c

Please sign in to comment.