Changeset 1a4ea01d in mainline


Ignore:
Timestamp:
2011-10-12T15:35:23Z (13 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
96646a6
Parents:
49a98c8
Message:

usb: Rename add_device ⇒ device_add

Location:
uspace
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/usbflbk/main.c

    r49a98c8 r1a4ea01d  
    4646 * @return Error code.
    4747 */
    48 static int usbfallback_add_device(usb_device_t *dev)
     48static int usbfallback_device_add(usb_device_t *dev)
    4949{
    5050        int rc;
     
    7474/** USB fallback driver ops. */
    7575static usb_driver_ops_t usbfallback_driver_ops = {
    76         .add_device = usbfallback_add_device,
     76        .device_add = usbfallback_device_add,
    7777};
    7878
  • uspace/drv/bus/usb/usbhid/main.c

    r49a98c8 r1a4ea01d  
    150150 * @retval EREFUSED if the device is not supported.
    151151 */
    152 static int usb_hid_add_device(usb_device_t *dev)
     152static int usb_hid_device_add(usb_device_t *dev)
    153153{
    154         usb_log_debug("usb_hid_add_device()\n");
     154        usb_log_debug("usb_hid_device_add()\n");
    155155       
    156156        if (dev == NULL) {
     
    185185 * supports unplug, more callbacks will be added. */
    186186static usb_driver_ops_t usb_hid_driver_ops = {
    187         .add_device = usb_hid_add_device,
     187        .device_add = usb_hid_device_add,
    188188};
    189189
  • uspace/drv/bus/usb/usbhub/main.c

    r49a98c8 r1a4ea01d  
    5959 * USB hub driver operations
    6060 *
    61  * The most important one is add_device, which is set to usb_hub_add_device.
     61 * The most important one is device_add, which is set to usb_hub_device_add.
    6262 */
    6363static usb_driver_ops_t usb_hub_driver_ops = {
    64         .add_device = usb_hub_add_device
     64        .device_add = usb_hub_device_add
    6565};
    6666
  • uspace/drv/bus/usb/usbhub/usbhub.c

    r49a98c8 r1a4ea01d  
    8484 * @return error code
    8585 */
    86 int usb_hub_add_device(usb_device_t *usb_dev)
     86int usb_hub_device_add(usb_device_t *usb_dev)
    8787{
    8888        assert(usb_dev);
  • uspace/drv/bus/usb/usbhub/usbhub.h

    r49a98c8 r1a4ea01d  
    7878};
    7979
    80 int usb_hub_add_device(usb_device_t *usb_dev);
     80int usb_hub_device_add(usb_device_t *usb_dev);
    8181
    8282bool hub_port_changes_callback(usb_device_t *dev,
  • uspace/drv/bus/usb/usbmast/main.c

    r49a98c8 r1a4ea01d  
    8787 * @return Error code.
    8888 */
    89 static int usbmast_add_device(usb_device_t *dev)
     89static int usbmast_device_add(usb_device_t *dev)
    9090{
    9191        int rc;
     
    295295/** USB mass storage driver ops. */
    296296static usb_driver_ops_t usbmast_driver_ops = {
    297         .add_device = usbmast_add_device,
     297        .device_add = usbmast_device_add,
    298298};
    299299
  • uspace/drv/bus/usb/usbmid/main.c

    r49a98c8 r1a4ea01d  
    4949 * @return Error code.
    5050 */
    51 static int usbmid_add_device(usb_device_t *dev)
     51static int usbmid_device_add(usb_device_t *dev)
    5252{
    5353        usb_log_info("Taking care of new MID `%s'.\n", dev->ddf_dev->name);
     
    6868/** USB MID driver ops. */
    6969static usb_driver_ops_t mid_driver_ops = {
    70         .add_device = usbmid_add_device,
     70        .device_add = usbmid_device_add,
    7171};
    7272
  • uspace/drv/bus/usb/usbmouse/main.c

    r49a98c8 r1a4ea01d  
    5050 *
    5151 */
    52 static int usbmouse_add_device(usb_device_t *dev)
     52static int usbmouse_device_add(usb_device_t *dev)
    5353{
    5454        int rc = usb_mouse_create(dev);
     
    8080/** USB mouse driver ops. */
    8181static usb_driver_ops_t mouse_driver_ops = {
    82         .add_device = usbmouse_add_device,
     82        .device_add = usbmouse_device_add,
    8383};
    8484
  • uspace/lib/usbdev/include/usb/dev/driver.h

    r49a98c8 r1a4ea01d  
    112112/** USB driver ops. */
    113113typedef struct {
    114         /** Callback when new device is about to be controlled by the driver. */
    115         int (*add_device)(usb_device_t *);
     114        /** Callback when a new device was added to the system. */
     115        int (*device_add)(usb_device_t *);
    116116} usb_driver_ops_t;
    117117
  • uspace/lib/usbdev/src/devdrv.c

    r49a98c8 r1a4ea01d  
    4141#include <assert.h>
    4242
    43 static int generic_add_device(ddf_dev_t *);
     43static int generic_device_add(ddf_dev_t *);
    4444
    4545static driver_ops_t generic_driver_ops = {
    46         .add_device = generic_add_device
     46        .add_device = generic_device_add
    4747};
    4848static driver_t generic_driver = {
     
    131131 * @return Error code.
    132132 */
    133 int generic_add_device(ddf_dev_t *gen_dev)
     133int generic_device_add(ddf_dev_t *gen_dev)
    134134{
    135135        assert(driver);
    136136        assert(driver->ops);
    137         assert(driver->ops->add_device);
     137        assert(driver->ops->device_add);
    138138
    139139        int rc;
     
    148148        }
    149149
    150         return driver->ops->add_device(dev);
     150        return driver->ops->device_add(dev);
    151151}
    152152
Note: See TracChangeset for help on using the changeset viewer.