1
0
Fork 0
forked from len0rd/rockbox

usb stack code police, fix some warnings and set svn keywords correctly

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14761 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Peter D'Hoye 2007-09-19 23:20:55 +00:00
parent 72e7ea22b5
commit e4363c116c
7 changed files with 52 additions and 25 deletions

View file

@ -20,6 +20,26 @@
#ifndef _USBSTACK_CONTROLLER_H_
#define _USBSTACK_CONTROLLER_H_
/*
* stack datatypes
*/
struct usb_response {
void* buf;
uint32_t length;
};
struct usb_ep {
const char name[15];
uint8_t type;
uint32_t ep_num; /* which endpoint? */
uint32_t pipe_num; /* which pipe? */
uint32_t maxpacket;
bool claimed;
struct usb_endpoint_descriptor *desc;
struct list_head list;
};
struct usb_controller {
const char* name;
enum usb_controller_type type;

View file

@ -27,26 +27,6 @@
#include "usbstack.h"
/*
* stack datatypes
*/
struct usb_response {
void* buf;
uint32_t length;
};
struct usb_ep {
const char name[15];
uint8_t type;
uint32_t ep_num; /* which endpoint? */
uint32_t pipe_num; /* which pipe? */
uint32_t maxpacket;
bool claimed;
struct usb_endpoint_descriptor *desc;
struct list_head list;
};
#include "usbstack/controller.h"
#include "usbstack/device.h"
#include "usbstack/host.h"

View file

@ -17,8 +17,9 @@
*
****************************************************************************/
#include "usb_serial.h"
#include <string.h>
#include "usb_serial.h"
#include "usbstack/utils.h"
static struct usb_dcd_controller_ops* ops;

View file

@ -17,8 +17,9 @@
*
****************************************************************************/
#include "usb_storage.h"
#include <string.h>
#include "usb_storage.h"
#include "usbstack/utils.h"
/*-------------------------------------------------------------------------*/

25
firmware/usbstack/utils.h Normal file
View file

@ -0,0 +1,25 @@
/***************************************************************************
* __________ __ ___.
* Open \______ \ ____ ____ | | _\_ |__ _______ ___
* Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
* Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
* Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
* \/ \/ \/ \/ \/
* $Id$
*
* Copyright (C) 2007 by Peter D'Hoye
*
* All files in this archive are subject to the GNU General Public License.
* See the file COPYING in the source tree root for full license agreement.
*
* This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
* KIND, either express or implied.
*
****************************************************************************/
#ifndef _USBSTACK_UTILS_H_
#define _USBSTACK_UTILS_H_
int usb_stack_get_string(struct usb_string* strings, int id, uint8_t* buf);
#endif /*_USBSTACK_UTILS_H_*/