From 0b43c656500a38acd321d93fc346f3fb0337b36a Mon Sep 17 00:00:00 2001 From: xj Date: Sun, 2 Jun 2024 23:16:08 -0700 Subject: [PATCH 1/8] Add USB folders --- Ubiquitous/XiZi_AIoT/services/fs/fs_server/include/block_io.h | 2 +- Ubiquitous/XiZi_AIoT/services/tools/mkfs/mkfs.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Ubiquitous/XiZi_AIoT/services/fs/fs_server/include/block_io.h b/Ubiquitous/XiZi_AIoT/services/fs/fs_server/include/block_io.h index f457436fd..2fe14d8af 100644 --- a/Ubiquitous/XiZi_AIoT/services/fs/fs_server/include/block_io.h +++ b/Ubiquitous/XiZi_AIoT/services/fs/fs_server/include/block_io.h @@ -18,7 +18,7 @@ // Block size #define BLOCK_SIZE 512 -#define NR_BIT_BLOCKS 2 +#define NR_BIT_BLOCKS 8 // bits size #define BITS 8 diff --git a/Ubiquitous/XiZi_AIoT/services/tools/mkfs/mkfs.h b/Ubiquitous/XiZi_AIoT/services/tools/mkfs/mkfs.h index b7d299bb9..e44e96798 100755 --- a/Ubiquitous/XiZi_AIoT/services/tools/mkfs/mkfs.h +++ b/Ubiquitous/XiZi_AIoT/services/tools/mkfs/mkfs.h @@ -49,7 +49,7 @@ Modification: #define ROOT_INUM 1 // root inode number #define BLOCK_SIZE 512 // block size #define NR_BIT_PER_BYTE 8 -#define NR_BIT_BLOCKS 2 +#define NR_BIT_BLOCKS 8 #define nr_blocks_total (BLOCK_SIZE * NR_BIT_PER_BYTE * NR_BIT_BLOCKS) // total number of blocks (including used blocks and free blocks) #define nr_inodes 200 // total number of inodes From c8bc2ddd05973c7442271988c76aeab3a0390635 Mon Sep 17 00:00:00 2001 From: xj Date: Sun, 2 Jun 2024 23:42:52 -0700 Subject: [PATCH 2/8] Add USB configure file --- .../XiZi_AIoT/services/drivers/usb/usb_config.h | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_config.h diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_config.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_config.h new file mode 100644 index 000000000..e691e6bd1 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_config.h @@ -0,0 +1,17 @@ +#ifndef USB_CONFIG_H_ +#define USB_CONFIG_H_ + + + + + + + + + + + + + + +#endif From 01e8e80c0eb583adc6fcb1c5edf46259b30b161c Mon Sep 17 00:00:00 2001 From: xj Date: Mon, 3 Jun 2024 00:47:04 -0700 Subject: [PATCH 3/8] Add USB source tree --- .../XiZi_AIoT/services/drivers/usb/class/hub/usb_hub.h | 8 ++++++++ .../XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.h | 9 +++++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_def.h | 8 ++++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_errno.h | 7 +++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_hc.h | 9 +++++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_list.h | 9 +++++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_log.h | 9 +++++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_mem.h | 8 ++++++++ .../XiZi_AIoT/services/drivers/usb/common/usb_util.h | 7 +++++++ 9 files changed, 74 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usb_hub.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_def.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_errno.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_hc.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_list.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_log.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_mem.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_util.h diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usb_hub.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usb_hub.h new file mode 100644 index 000000000..de5074663 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usb_hub.h @@ -0,0 +1,8 @@ +#ifndef USB_HUB_H_ +#define USB_HUB_H_ + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.h new file mode 100644 index 000000000..0f4d3cb53 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.h @@ -0,0 +1,9 @@ +#ifndef USBH_HUB_H_ +#define USBH_HUB_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_def.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_def.h new file mode 100644 index 000000000..31dded28c --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_def.h @@ -0,0 +1,8 @@ +#ifndef USB_DEF_H_ +#define USB_DEF_H_ + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_errno.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_errno.h new file mode 100644 index 000000000..5f7a59859 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_errno.h @@ -0,0 +1,7 @@ +#ifndef USB_ERROR_H_ +#define USB_ERROR_H_ + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_hc.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_hc.h new file mode 100644 index 000000000..fc910b9b8 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_hc.h @@ -0,0 +1,9 @@ +#ifndef USB_HC_H_ +#define USB_HC_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_list.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_list.h new file mode 100644 index 000000000..44f28777b --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_list.h @@ -0,0 +1,9 @@ +#ifndef USB_LIST_H_ +#define USB_LIST_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_log.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_log.h new file mode 100644 index 000000000..09b3c911a --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_log.h @@ -0,0 +1,9 @@ +#ifndef USB_LOG_H_ +#define USB_LOG_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_mem.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_mem.h new file mode 100644 index 000000000..b5118468c --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_mem.h @@ -0,0 +1,8 @@ +#ifndef USB_MEM_H_ +#define USB_MEM_H_ + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_util.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_util.h new file mode 100644 index 000000000..5f6aa22d1 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/common/usb_util.h @@ -0,0 +1,7 @@ +#ifndef USB_UTIL_H_ +#define USB_TIIL_H_ + + + + +#endif From 730d3be87bed18f3484d0ebfb9c3dbcbc8344685 Mon Sep 17 00:00:00 2001 From: xj Date: Mon, 3 Jun 2024 01:12:51 -0700 Subject: [PATCH 4/8] Add USB source tree --- .../XiZi_AIoT/services/drivers/usb/core/usbh_core.h | 8 ++++++++ .../XiZi_AIoT/services/drivers/usb/osal/usb_osal.h | 8 ++++++++ .../services/drivers/usb/port/xhci/usb_hc_xhci.h | 9 +++++++++ .../XiZi_AIoT/services/drivers/usb/port/xhci/xhci.h | 9 +++++++++ .../XiZi_AIoT/services/drivers/usb/port/xhci/xhci_reg.h | 9 +++++++++ 5 files changed, 43 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/core/usbh_core.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_reg.h diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/core/usbh_core.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/core/usbh_core.h new file mode 100644 index 000000000..1a2de80c4 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/core/usbh_core.h @@ -0,0 +1,8 @@ +#ifndef USBH_CORE_H_ +#define USBH_CORE_H_ + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal.h new file mode 100644 index 000000000..052c39126 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal.h @@ -0,0 +1,8 @@ +#ifndef USB_OSAL_H_ +#define USB_OSAL_H_ + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.h new file mode 100644 index 000000000..077e316ff --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.h @@ -0,0 +1,9 @@ +#ifndef USB_HC_XHCI_H_ +#define USB_HC_XHCI_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.h new file mode 100644 index 000000000..4b09aa70a --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.h @@ -0,0 +1,9 @@ +#ifndef XHCI_H_ +#define XHCI_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_reg.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_reg.h new file mode 100644 index 000000000..0d9aede23 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_reg.h @@ -0,0 +1,9 @@ +#ifndef XHCI_REG_H_ +#define XHCI_REG_H_ + + + + + + +#endif From b9cd006f8f798a97a3eb161b5b8b50bbe2413b65 Mon Sep 17 00:00:00 2001 From: xj Date: Mon, 3 Jun 2024 01:19:34 -0700 Subject: [PATCH 5/8] Add USB source tree --- Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.c | 1 + Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.h | 9 +++++++++ 2 files changed, 10 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.c create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.h diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.c new file mode 100644 index 000000000..75435d4c2 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.c @@ -0,0 +1 @@ +#include "usb_host.h" diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.h new file mode 100644 index 000000000..e6e9f9efb --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/usb_host.h @@ -0,0 +1,9 @@ +#ifndef USB_HOST_H_ +#define USB_HOST_H_ + + + + + + +#endif From c5263acba556f56a08dcd4904fc37d440c47422b Mon Sep 17 00:00:00 2001 From: xj Date: Mon, 3 Jun 2024 01:31:46 -0700 Subject: [PATCH 6/8] Add USB source tree --- .../XiZi_AIoT/services/drivers/usb/class/cdc/usb_cdc.h | 9 +++++++++ .../services/drivers/usb/class/wireless/rndis_protocol.h | 9 +++++++++ .../services/drivers/usb/class/wireless/usbh_rndis.c | 1 + .../services/drivers/usb/class/wireless/usbh_rndis.h | 9 +++++++++ 4 files changed, 28 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/cdc/usb_cdc.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/rndis_protocol.h create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.c create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.h diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/cdc/usb_cdc.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/cdc/usb_cdc.h new file mode 100644 index 000000000..04e864af1 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/cdc/usb_cdc.h @@ -0,0 +1,9 @@ +#ifndef USB_CDC_H_ +#define USB_CDC_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/rndis_protocol.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/rndis_protocol.h new file mode 100644 index 000000000..af0ed8c17 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/rndis_protocol.h @@ -0,0 +1,9 @@ +#ifndef RNDIS_PROTOCOL_H_ +#define RNDIS_PROTOCOL_H_ + + + + + + +#endif diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.c new file mode 100644 index 000000000..500bb1415 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.c @@ -0,0 +1 @@ +#include "usbh_rndis.h" diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.h b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.h new file mode 100644 index 000000000..c29198b50 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/wireless/usbh_rndis.h @@ -0,0 +1,9 @@ +#ifndef USBH_RNDIS_H_ +#define USBH_RNDIS_H_ + + + + + + +#endif From d2dd347ed54687c14c49bcd88c0aaefc872603c1 Mon Sep 17 00:00:00 2001 From: xj Date: Mon, 3 Jun 2024 01:48:32 -0700 Subject: [PATCH 7/8] Add USB source tree --- Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.c | 1 + Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal_xiuos.c | 1 + 2 files changed, 2 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.c create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal_xiuos.c diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.c new file mode 100644 index 000000000..41cd7cc79 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/class/hub/usbh_hub.c @@ -0,0 +1 @@ +#include "usbh_hub.h" diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal_xiuos.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal_xiuos.c new file mode 100644 index 000000000..391a315c8 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/osal/usb_osal_xiuos.c @@ -0,0 +1 @@ +#include "usb_osal.h" From ea8b1f5374842d339328af3818abdd6d8b247786 Mon Sep 17 00:00:00 2001 From: xj Date: Mon, 3 Jun 2024 01:55:57 -0700 Subject: [PATCH 8/8] Add USB source tree --- .../XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.c | 1 + Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.c | 1 + Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_dbg.c | 1 + 3 files changed, 3 insertions(+) create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.c create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.c create mode 100644 Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_dbg.c diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.c new file mode 100644 index 000000000..c9c52dbe9 --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/usb_hc_xhci.c @@ -0,0 +1 @@ +#include "usb_hc_xhci.h" diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.c new file mode 100644 index 000000000..8dc67c9cc --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci.c @@ -0,0 +1 @@ +#include "xhci.h" diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_dbg.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_dbg.c new file mode 100644 index 000000000..8dc67c9cc --- /dev/null +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/port/xhci/xhci_dbg.c @@ -0,0 +1 @@ +#include "xhci.h"