Changeset 23f40280 in mainline
- Timestamp:
- 2011-05-08T20:43:00Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7e7b791
- Parents:
- 511cfc8
- Location:
- uspace/drv
- Files:
-
- 20 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/ohci/batch.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 /** @addtogroup drvusb uhcihc28 /** @addtogroup drvusbohci 29 29 * @{ 30 30 */ 31 31 /** @file 32 * @brief UHCI driver USB transaction structure32 * @brief OHCI driver USB transaction structure 33 33 */ 34 #ifndef DRV_ UHCI_BATCH_H35 #define DRV_ UHCI_BATCH_H34 #ifndef DRV_OHCI_BATCH_H 35 #define DRV_OHCI_BATCH_H 36 36 37 37 #include <usbhc_iface.h> -
uspace/drv/ohci/endpoint_list.h
r511cfc8 r23f40280 41 41 #include "utils/malloc32.h" 42 42 43 typedef struct endpoint_list 44 { 43 typedef struct endpoint_list { 45 44 fibril_mutex_t guard; 46 45 ed_t *list_head; -
uspace/drv/ohci/iface.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 29 28 /** @addtogroup drvusbohci 30 29 * @{ -
uspace/drv/ohci/ohci.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 29 28 /** @addtogroup drvusbohci 30 29 * @{ -
uspace/drv/ohci/ohci_regs.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 29 28 /** @addtogroup drvusbohcihc 30 29 * @{ -
uspace/drv/ohci/pci.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 29 28 /** @addtogroup drvusbohci 30 29 * @{ -
uspace/drv/ohci/root_hub.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 29 28 /** @addtogroup drvusbohci 30 29 * @{ -
uspace/drv/ohci/utils/malloc32.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 /** @addtogroup usb28 /** @addtogroup drvusbohci 29 29 * @{ 30 30 */ 31 31 /** @file 32 * @brief UHCI driver32 * @brief OHCI driver 33 33 */ 34 #ifndef DRV_ UHCI_TRANSLATOR_H35 #define DRV_ UHCI_TRANSLATOR_H34 #ifndef DRV_OHCI_UTILS_MALLOC32_H 35 #define DRV_OHCI_UTILS_MALLOC32_H 36 36 37 37 #include <assert.h> … … 40 40 #include <mem.h> 41 41 #include <as.h> 42 43 #define UHCI_REQUIRED_PAGE_SIZE 409644 42 45 43 /** Get physical address translation … … 61 59 * 62 60 * @param[in] size Size of the required memory space 63 * @return Address of the al ligned and big enough memory place, NULL on failure.61 * @return Address of the aligned and big enough memory place, NULL on failure. 64 62 */ 65 63 static inline void * malloc32(size_t size) … … 72 70 static inline void free32(void *addr) 73 71 { if (addr) free(addr); } 74 /*----------------------------------------------------------------------------*/75 /** Create 4KB page mapping76 *77 * @return Address of the mapped page, NULL on failure.78 */79 static inline void * get_page(void)80 {81 void * free_address = as_get_mappable_page(UHCI_REQUIRED_PAGE_SIZE);82 assert(free_address);83 if (free_address == 0)84 return NULL;85 void* ret =86 as_area_create(free_address, UHCI_REQUIRED_PAGE_SIZE,87 AS_AREA_READ | AS_AREA_WRITE);88 if (ret != free_address)89 return NULL;90 return ret;91 }92 93 72 #endif 94 73 /** -
uspace/drv/uhci-hcd/batch.c
r511cfc8 r23f40280 70 70 * @param[in] ep Communication target 71 71 * @param[in] buffer Data source/destination. 72 * @param[in] size Size of the buffer.72 * @param[in] buffer_size Size of the buffer. 73 73 * @param[in] setup_buffer Setup data source (if not NULL) 74 74 * @param[in] setup_size Size of setup_buffer (should be always 8) -
uspace/drv/uhci-hcd/hc.c
r511cfc8 r23f40280 61 61 * @param[in] instance Memory place to initialize. 62 62 * @param[in] regs Address of I/O control registers. 63 * @param[in] size Size of I/O control registers. 63 * @param[in] reg_size Size of I/O control registers. 64 * @param[in] interrupts True if hw interrupts should be used. 64 65 * @return Error code. 65 66 * @note Should be called only once on any structure. -
uspace/drv/uhci-hcd/hc.h
r511cfc8 r23f40280 33 33 * @brief UHCI host controller driver structure 34 34 */ 35 #ifndef DRV_UHCI_ UHCI_HC_H36 #define DRV_UHCI_ UHCI_HC_H35 #ifndef DRV_UHCI_HC_H 36 #define DRV_UHCI_HC_H 37 37 38 38 #include <fibril.h> -
uspace/drv/uhci-hcd/hw_struct/link_pointer.h
r511cfc8 r23f40280 32 32 * @brief UHCI driver 33 33 */ 34 #ifndef DRV_UHCI_ LINK_POINTER_H35 #define DRV_UHCI_ LINK_POINTER_H34 #ifndef DRV_UHCI_HW_STRUCT_LINK_POINTER_H 35 #define DRV_UHCI_HW_STRUCT_LINK_POINTER_H 36 36 37 37 /* UHCI link pointer, used by many data structures */ -
uspace/drv/uhci-hcd/hw_struct/queue_head.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 /** @addtogroup drv 28 /** @addtogroup drvusbuhcihc 29 29 * @{ 30 30 */ … … 32 32 * @brief UHCI driver 33 33 */ 34 #ifndef DRV_UHCI_ QH_H35 #define DRV_UHCI_ QH_H34 #ifndef DRV_UHCI_HW_STRUCT_QH_H 35 #define DRV_UHCI_HW_STRUCT_QH_H 36 36 #include <assert.h> 37 37 … … 65 65 * 66 66 * @param[in] instance qh_t structure to use. 67 * @param[in] pa Physical address of the next queue head.67 * @param[in] next Address of the next queue. 68 68 * 69 69 * Adds proper flag. If the pointer is NULL, sets next to terminal NULL. … … 81 81 /** Set queue head element pointer 82 82 * 83 * @param[in] instance qh_t structure to initialize.84 * @param[in] pa Physical address of the TD structure.83 * @param[in] instance qh_t structure to use. 84 * @param[in] td Transfer descriptor to set as the first element. 85 85 * 86 86 * Adds proper flag. If the pointer is NULL, sets element to terminal NULL. -
uspace/drv/uhci-hcd/hw_struct/transfer_descriptor.h
r511cfc8 r23f40280 32 32 * @brief UHCI driver 33 33 */ 34 #ifndef DRV_UHCI_ TRANSFER_DESCRIPTOR_H35 #define DRV_UHCI_ TRANSFER_DESCRIPTOR_H34 #ifndef DRV_UHCI_HW_STRUCT_TRANSFER_DESCRIPTOR_H 35 #define DRV_UHCI_HW_STRUCT_TRANSFER_DESCRIPTOR_H 36 36 37 37 #include <mem.h> -
uspace/drv/uhci-hcd/root_hub.h
r511cfc8 r23f40280 33 33 * @brief UHCI driver 34 34 */ 35 #ifndef DRV_UHCI_ UHCI_RH_H36 #define DRV_UHCI_ UHCI_RH_H35 #ifndef DRV_UHCI_RH_H 36 #define DRV_UHCI_RH_H 37 37 38 38 #include <ddf/driver.h> -
uspace/drv/uhci-hcd/uhci.c
r511cfc8 r23f40280 161 161 /** Initialize hc and rh DDF structures and their respective drivers. 162 162 * 163 * @param[in] instance UHCI structure to use.164 163 * @param[in] device DDF instance of the device to use. 165 164 * … … 167 166 * - gets device's hw resources 168 167 * - disables UHCI legacy support (PCI config space) 169 * - a sks for interrupt168 * - attempts to enable interrupts 170 169 * - registers interrupt handler 171 170 */ -
uspace/drv/uhci-hcd/utils/malloc32.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 /** @addtogroup usb28 /** @addtogroup drvusbuhci 29 29 * @{ 30 30 */ … … 32 32 * @brief UHCI driver 33 33 */ 34 #ifndef DRV_UHCI_ TRANSLATOR_H35 #define DRV_UHCI_ TRANSLATOR_H34 #ifndef DRV_UHCI_UTILS_MALLOC32_H 35 #define DRV_UHCI_UTILS_MALLOC32_H 36 36 37 37 #include <assert.h> -
uspace/drv/uhci-hcd/utils/slab.c
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 /** @addtogroup usb28 /** @addtogroup drvusbuhcihc 29 29 * @{ 30 30 */ -
uspace/drv/uhci-hcd/utils/slab.h
r511cfc8 r23f40280 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 /** @addtogroup usb28 /** @addtogroup drvusbuhcihc 29 29 * @{ 30 30 */ … … 32 32 * @brief UHCI driver 33 33 */ 34 #ifndef DRV_UHCI_ SLAB_H35 #define DRV_UHCI_ SLAB_H34 #ifndef DRV_UHCI_UTILS_SLAB_H 35 #define DRV_UHCI_UTILS_SLAB_H 36 36 37 37 #include <bool.h> -
uspace/drv/uhci-rhd/port.c
r511cfc8 r23f40280 65 65 * 66 66 * @param[in] port Structure to use. 67 * @param[in] val ueNew register value.67 * @param[in] val New register value. 68 68 * @return Error code. (Always EOK) 69 69 */ … … 77 77 * 78 78 * @param[in] port Memory structure to use. 79 * @param[in] addr Address of I/O register.79 * @param[in] address Address of I/O register. 80 80 * @param[in] number Port number. 81 81 * @param[in] usec Polling interval.
Note:
See TracChangeset
for help on using the changeset viewer.