avr32dci.c (228483) | avr32dci.c (233774) |
---|---|
1#include <sys/cdefs.h> | 1#include <sys/cdefs.h> |
2__FBSDID("$FreeBSD: head/sys/dev/usb/controller/avr32dci.c 228483 2011-12-14 00:28:54Z hselasky $"); | 2__FBSDID("$FreeBSD: head/sys/dev/usb/controller/avr32dci.c 233774 2012-04-02 10:50:42Z hselasky $"); |
3 4/*- 5 * Copyright (c) 2009 Hans Petter Selasky. All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions 9 * are met: 10 * 1. Redistributions of source code must retain the above copyright --- 1473 unchanged lines hidden (view full) --- 1484 .bDescriptorType = UDESC_ENDPOINT, 1485 .bEndpointAddress = (UE_DIR_IN | AVR32_INTR_ENDPT), 1486 .bmAttributes = UE_INTERRUPT, 1487 .wMaxPacketSize[0] = 8, 1488 .bInterval = 255, 1489 }, 1490}; 1491 | 3 4/*- 5 * Copyright (c) 2009 Hans Petter Selasky. All rights reserved. 6 * 7 * Redistribution and use in source and binary forms, with or without 8 * modification, are permitted provided that the following conditions 9 * are met: 10 * 1. Redistributions of source code must retain the above copyright --- 1473 unchanged lines hidden (view full) --- 1484 .bDescriptorType = UDESC_ENDPOINT, 1485 .bEndpointAddress = (UE_DIR_IN | AVR32_INTR_ENDPT), 1486 .bmAttributes = UE_INTERRUPT, 1487 .wMaxPacketSize[0] = 8, 1488 .bInterval = 255, 1489 }, 1490}; 1491 |
1492#define HSETW(ptr, val) ptr = { (uint8_t)(val), (uint8_t)((val) >> 8) } 1493 |
|
1492static const struct usb_hub_descriptor_min avr32dci_hubd = { 1493 .bDescLength = sizeof(avr32dci_hubd), 1494 .bDescriptorType = UDESC_HUB, 1495 .bNbrPorts = 1, | 1494static const struct usb_hub_descriptor_min avr32dci_hubd = { 1495 .bDescLength = sizeof(avr32dci_hubd), 1496 .bDescriptorType = UDESC_HUB, 1497 .bNbrPorts = 1, |
1496 .wHubCharacteristics[0] = 1497 (UHD_PWR_NO_SWITCH | UHD_OC_INDIVIDUAL) & 0xFF, 1498 .wHubCharacteristics[1] = 1499 (UHD_PWR_NO_SWITCH | UHD_OC_INDIVIDUAL) >> 8, | 1498 HSETW(.wHubCharacteristics, (UHD_PWR_NO_SWITCH | UHD_OC_INDIVIDUAL)), |
1500 .bPwrOn2PwrGood = 50, 1501 .bHubContrCurrent = 0, 1502 .DeviceRemovable = {0}, /* port is removable */ 1503}; 1504 1505#define STRING_LANG \ 1506 0x09, 0x04, /* American English */ 1507 --- 598 unchanged lines hidden --- | 1499 .bPwrOn2PwrGood = 50, 1500 .bHubContrCurrent = 0, 1501 .DeviceRemovable = {0}, /* port is removable */ 1502}; 1503 1504#define STRING_LANG \ 1505 0x09, 0x04, /* American English */ 1506 --- 598 unchanged lines hidden --- |