Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 221867
b: refs/heads/master
c: 3924996
h: refs/heads/master
i:
  221865: ee77a3e
  221863: c19534d
v: v3
  • Loading branch information
Nicolas Pitre committed Oct 21, 2010
1 parent 530f3f1 commit 35444a9
Show file tree
Hide file tree
Showing 4 changed files with 17 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: d3491820e8a65c4a51c8e2a165c6a13f864101ba
refs/heads/master: 3924996bab2845bdf9a9d16ff7c20445de1ab55d
14 changes: 13 additions & 1 deletion trunk/arch/arm/mach-kirkwood/ts41x-setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@
#include "mpp.h"
#include "tsx1x-common.h"

/* for the PCIe reset workaround */
#include <plat/pcie.h>


#define QNAP_TS41X_JUMPER_JP1 45

static struct i2c_board_info __initdata qnap_ts41x_i2c_rtc = {
Expand Down Expand Up @@ -140,8 +144,16 @@ static void __init qnap_ts41x_init(void)

static int __init ts41x_pci_init(void)
{
if (machine_is_ts41x())
if (machine_is_ts41x()) {
/*
* Without this explicit reset, the PCIe SATA controller
* (Marvell 88sx7042/sata_mv) is known to stop working
* after a few minutes.
*/
orion_pcie_reset((void __iomem *)PCIE_VIRT_BASE);

kirkwood_pcie_init(KW_PCIE0);
}

return 0;
}
Expand Down
3 changes: 3 additions & 0 deletions trunk/arch/arm/plat-orion/include/plat/pcie.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,15 @@
#ifndef __PLAT_PCIE_H
#define __PLAT_PCIE_H

struct pci_bus;

u32 orion_pcie_dev_id(void __iomem *base);
u32 orion_pcie_rev(void __iomem *base);
int orion_pcie_link_up(void __iomem *base);
int orion_pcie_x4_mode(void __iomem *base);
int orion_pcie_get_local_bus_nr(void __iomem *base);
void orion_pcie_set_local_bus_nr(void __iomem *base, int nr);
void orion_pcie_reset(void __iomem *base);
void orion_pcie_setup(void __iomem *base,
struct mbus_dram_target_info *dram);
int orion_pcie_rd_conf(void __iomem *base, struct pci_bus *bus,
Expand Down
5 changes: 0 additions & 5 deletions trunk/arch/arm/plat-orion/pcie.c
Original file line number Diff line number Diff line change
Expand Up @@ -181,11 +181,6 @@ void __init orion_pcie_setup(void __iomem *base,
u16 cmd;
u32 mask;

/*
* soft reset PCIe unit
*/
orion_pcie_reset(base);

/*
* Point PCIe unit MBUS decode windows to DRAM space.
*/
Expand Down

0 comments on commit 35444a9

Please sign in to comment.