Explorar o código

riscv: Enable usb driver

TekkamanV %!s(int64=3) %!d(string=hai) anos
pai
achega
e640835074
Modificáronse 2 ficheiros con 14 adicións e 2 borrados
  1. 13 1
      drivers/usb/common/fsl-errata.c
  2. 1 1
      include/fsl_usb.h

+ 13 - 1
drivers/usb/common/fsl-errata.c

@@ -14,8 +14,20 @@
 #include <asm/arch/clock.h>
 #endif
 
+#if defined(CONFIG_RISCV)
+u32 get_svr(void)
+{
+	return 0;
+}
+
+u32 SVR_SOC_VER(u32 svr)
+{
+	return 0;
+}
+#endif
+
 /* USB Erratum Checking code */
-#if defined(CONFIG_PPC) || defined(CONFIG_ARM)
+#if defined(CONFIG_PPC) || defined(CONFIG_ARM) || defined(CONFIG_RISCV)
 bool has_dual_phy(void)
 {
 	u32 svr = get_svr();

+ 1 - 1
include/fsl_usb.h

@@ -85,7 +85,7 @@ struct ccsr_usb_phy {
 #endif
 
 /* USB Erratum Checking code */
-#if defined(CONFIG_PPC) || defined(CONFIG_ARM)
+#if defined(CONFIG_PPC) || defined(CONFIG_ARM) || defined(CONFIG_RISCV)
 bool has_dual_phy(void);
 bool has_erratum_a005275(void);
 bool has_erratum_a006261(void);