diff options
| author | hathach <[email protected]> | 2013-04-05 14:26:28 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2013-04-05 14:26:28 +0700 |
| commit | d616fa6c1000e78ecf6e5e73ed080832112ef536 (patch) | |
| tree | 4e213ef15d1623e44ff47d77c30fb282a9f09639 /tests/test/host | |
| parent | 10f5bce0df2700ce47f3466b838486a76385ce2b (diff) | |
continue on refratoring
Diffstat (limited to 'tests/test/host')
| -rw-r--r-- | tests/test/host/ehci/test_ehci_init.c | 3 | ||||
| -rw-r--r-- | tests/test/host/ehci/test_ehci_isr.c | 3 | ||||
| -rw-r--r-- | tests/test/host/ehci/test_ehci_usbh_hcd_integration.c | 3 | ||||
| -rw-r--r-- | tests/test/host/ehci/test_pipe_bulk_xfer.c | 3 | ||||
| -rw-r--r-- | tests/test/host/ehci/test_pipe_control_xfer.c | 3 | ||||
| -rw-r--r-- | tests/test/host/ehci/test_pipe_interrupt_xfer.c | 3 |
6 files changed, 6 insertions, 12 deletions
diff --git a/tests/test/host/ehci/test_ehci_init.c b/tests/test/host/ehci/test_ehci_init.c index e83827be5..4876edbdd 100644 --- a/tests/test/host/ehci/test_ehci_init.c +++ b/tests/test/host/ehci/test_ehci_init.c @@ -54,8 +54,7 @@ usbh_device_info_t usbh_devices[TUSB_CFG_HOST_DEVICE_MAX+1]; //--------------------------------------------------------------------+ void setUp(void) { - memclr_(&lpc_usb0, sizeof(LPC_USB0_Type)); - memclr_(&lpc_usb1, sizeof(LPC_USB1_Type)); + ehci_controller_init(); } void tearDown(void) diff --git a/tests/test/host/ehci/test_ehci_isr.c b/tests/test/host/ehci/test_ehci_isr.c index 40613b53a..7539500a5 100644 --- a/tests/test/host/ehci/test_ehci_isr.c +++ b/tests/test/host/ehci/test_ehci_isr.c @@ -53,8 +53,7 @@ uint8_t hostid; ehci_registers_t * regs; void setUp(void) { - memclr_(&lpc_usb0, sizeof(LPC_USB0_Type)); - memclr_(&lpc_usb1, sizeof(LPC_USB1_Type)); + ehci_controller_init(); hostid = RANDOM(CONTROLLER_HOST_NUMBER) + TEST_CONTROLLER_HOST_START_INDEX; regs = get_operational_register(hostid); diff --git a/tests/test/host/ehci/test_ehci_usbh_hcd_integration.c b/tests/test/host/ehci/test_ehci_usbh_hcd_integration.c index ee640fff2..0e059df88 100644 --- a/tests/test/host/ehci/test_ehci_usbh_hcd_integration.c +++ b/tests/test/host/ehci/test_ehci_usbh_hcd_integration.c @@ -63,8 +63,7 @@ ehci_qhd_t *period_head; void setUp(void) { - memclr_(&lpc_usb0, sizeof(LPC_USB0_Type)); - memclr_(&lpc_usb1, sizeof(LPC_USB1_Type)); + ehci_controller_init(); memclr_(usbh_devices, sizeof(usbh_device_info_t)*(TUSB_CFG_HOST_DEVICE_MAX+1)); hub_addr = hub_port = 0; diff --git a/tests/test/host/ehci/test_pipe_bulk_xfer.c b/tests/test/host/ehci/test_pipe_bulk_xfer.c index a4a23cda7..15e33d639 100644 --- a/tests/test/host/ehci/test_pipe_bulk_xfer.c +++ b/tests/test/host/ehci/test_pipe_bulk_xfer.c @@ -85,8 +85,7 @@ tusb_descriptor_endpoint_t const desc_ept_bulk_out = //--------------------------------------------------------------------+ void setUp(void) { - memclr_(&lpc_usb0, sizeof(LPC_USB0_Type)); - memclr_(&lpc_usb1, sizeof(LPC_USB1_Type)); + ehci_controller_init(); memclr_(usbh_devices, sizeof(usbh_device_info_t)*(TUSB_CFG_HOST_DEVICE_MAX+1)); memclr_(xfer_data, sizeof(xfer_data)); diff --git a/tests/test/host/ehci/test_pipe_control_xfer.c b/tests/test/host/ehci/test_pipe_control_xfer.c index 4494d225a..3c062dae8 100644 --- a/tests/test/host/ehci/test_pipe_control_xfer.c +++ b/tests/test/host/ehci/test_pipe_control_xfer.c @@ -68,8 +68,7 @@ ehci_qtd_t *p_status; //--------------------------------------------------------------------+ void setUp(void) { - memclr_(&lpc_usb0, sizeof(LPC_USB0_Type)); - memclr_(&lpc_usb1, sizeof(LPC_USB1_Type)); + ehci_controller_init(); memclr_(usbh_devices, sizeof(usbh_device_info_t)*(TUSB_CFG_HOST_DEVICE_MAX+1)); memclr_(xfer_data, sizeof(xfer_data)); diff --git a/tests/test/host/ehci/test_pipe_interrupt_xfer.c b/tests/test/host/ehci/test_pipe_interrupt_xfer.c index 81a0f990f..d1ef66fb0 100644 --- a/tests/test/host/ehci/test_pipe_interrupt_xfer.c +++ b/tests/test/host/ehci/test_pipe_interrupt_xfer.c @@ -85,8 +85,7 @@ tusb_descriptor_endpoint_t const desc_ept_interupt_out = //--------------------------------------------------------------------+ void setUp(void) { - memclr_(&lpc_usb0, sizeof(LPC_USB0_Type)); - memclr_(&lpc_usb1, sizeof(LPC_USB1_Type)); + ehci_controller_init(); memclr_(usbh_devices, sizeof(usbh_device_info_t)*(TUSB_CFG_HOST_DEVICE_MAX+1)); memclr_(xfer_data, sizeof(xfer_data)); |
