Example #1
0
static int mpc834xemds_usb_cfg(void)
{
	struct device_node *np;
	void __iomem *bcsr_regs = NULL;
	u8 bcsr5;

	mpc834x_usb_cfg();
	
	np = of_find_node_by_name(NULL, "bcsr");
	if (np) {
		struct resource res;

		of_address_to_resource(np, 0, &res);
		bcsr_regs = ioremap(res.start, resource_size(&res));
		of_node_put(np);
	}
	if (!bcsr_regs)
		return -1;

	bcsr5 = in_8(bcsr_regs + 5);
	if (!(bcsr5 & BCSR5_INT_USB))
		out_8(bcsr_regs + 5, (bcsr5 | BCSR5_INT_USB));
	iounmap(bcsr_regs);
	return 0;
}
Example #2
0
/* ************************************************************************
 *
 * Setup the architecture
 *
 */
static void __init asp834x_setup_arch(void)
{
    if (ppc_md.progress)
        ppc_md.progress("asp834x_setup_arch()", 0);

    mpc834x_usb_cfg();
}
Example #3
0
static int mpc834xemds_usb_cfg(void)
{
    struct device_node *np;
    void __iomem *bcsr_regs = NULL;
    u8 bcsr5;

    mpc834x_usb_cfg();
    /* Map BCSR area */
    np = of_find_node_by_name(NULL, "bcsr");
    if (np) {
        struct resource res;

        of_address_to_resource(np, 0, &res);
        bcsr_regs = ioremap(res.start, res.end - res.start + 1);
        of_node_put(np);
    }
    if (!bcsr_regs)
        return -1;

    /*
     * if Processor Board is plugged into PIB board,
     * force to use the PHY on Processor Board
     */
    bcsr5 = in_8(bcsr_regs + 5);
    if (!(bcsr5 & BCSR5_INT_USB))
        out_8(bcsr_regs + 5, (bcsr5 | BCSR5_INT_USB));
    iounmap(bcsr_regs);
    return 0;
}
Example #4
0
static void __init mpc834x_itx_setup_arch(void)
{
	if (ppc_md.progress)
		ppc_md.progress("mpc834x_itx_setup_arch()", 0);

	mpc83xx_setup_pci();

	mpc834x_usb_cfg();
}
Example #5
0
/* ************************************************************************
 *
 * Setup the architecture
 *
 */
static void __init mpc834x_itx_setup_arch(void)
{
#ifdef CONFIG_PCI
	struct device_node *np;
#endif

	if (ppc_md.progress)
		ppc_md.progress("mpc834x_itx_setup_arch()", 0);

#ifdef CONFIG_PCI
	for_each_compatible_node(np, "pci", "fsl,mpc8349-pci")
		mpc83xx_add_bridge(np);
#endif

	mpc834x_usb_cfg();
}