]> git.ipfire.org Git - people/ms/u-boot.git/blob - arch/powerpc/cpu/ppc4xx/usb.c
drivers, block: remove sil680 driver
[people/ms/u-boot.git] / arch / powerpc / cpu / ppc4xx / usb.c
1 /*
2 * (C) Copyright 2007
3 * Markus Klotzbuecher, DENX Software Engineering <mk@denx.de>
4 *
5 * SPDX-License-Identifier: GPL-2.0+
6 */
7
8 #include <common.h>
9
10 #if defined(CONFIG_USB_OHCI_NEW) && defined(CONFIG_SYS_USB_OHCI_CPU_INIT)
11
12 #ifdef CONFIG_4xx_DCACHE
13 #include <asm/mmu.h>
14 DECLARE_GLOBAL_DATA_PTR;
15 #endif
16
17 int usb_cpu_init(void)
18 {
19 #ifdef CONFIG_4xx_DCACHE
20 /* disable cache */
21 change_tlb(gd->bd->bi_memstart, gd->bd->bi_memsize, TLB_WORD2_I_ENABLE);
22 #endif
23
24 return 0;
25 }
26
27 int usb_cpu_stop(void)
28 {
29 #ifdef CONFIG_4xx_DCACHE
30 /* enable cache */
31 change_tlb(gd->bd->bi_memstart, gd->bd->bi_memsize, 0);
32 #endif
33 return 0;
34 }
35
36 int usb_cpu_init_fail(void)
37 {
38 #ifdef CONFIG_4xx_DCACHE
39 /* enable cache */
40 change_tlb(gd->bd->bi_memstart, gd->bd->bi_memsize, 0);
41 #endif
42 return 0;
43 }
44
45 #endif /* defined(CONFIG_USB_OHCI) && defined(CONFIG_SYS_USB_OHCI_CPU_INIT) */