X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=carlfw%2Finclude%2Fusb.h;h=fb258bf16bd37be843d3542f26fa771c921e76b4;hb=aad02e753490f33725d407b63b31e76c58f01caa;hp=2098638cf7d6a8d0b01a17535b1b7beaa6f703dd;hpb=6476369c2c6d4ba487408cb5daff8df0480d6b4a;p=carl9170fw.git diff --git a/carlfw/include/usb.h b/carlfw/include/usb.h index 2098638..fb258bf 100644 --- a/carlfw/include/usb.h +++ b/carlfw/include/usb.h @@ -6,7 +6,7 @@ * Copyright (c) 2000-2005 ZyDAS Technology Corporation * Copyright (c) 2007-2009 Atheros Communications, Inc. * Copyright 2009 Johannes Berg - * Copyright 2009, 2010 Christian Lamparter + * Copyright 2009-2011 Christian Lamparter * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -141,6 +141,12 @@ static inline __inline void usb_clear_input_ep_toggle(unsigned int ep) ~AR9170_USB_EP_IN_TOGGLE); } +static inline __inline void usb_clear_input_ep_stall(unsigned int ep) +{ + andl(AR9170_USB_REG_EP_IN_MAX_SIZE_HIGH + (ep << 1), + ~AR9170_USB_EP_IN_STALL); +} + static inline __inline void usb_set_input_ep_toggle(unsigned int ep) { orl(AR9170_USB_REG_EP_IN_MAX_SIZE_HIGH + (ep << 1), @@ -159,6 +165,12 @@ static inline __inline void usb_set_output_ep_toggle(unsigned int ep) AR9170_USB_EP_OUT_TOGGLE); } +static inline __inline void usb_clear_output_ep_stall(unsigned int ep) +{ + andl(AR9170_USB_REG_EP_OUT_MAX_SIZE_HIGH + (ep << 1), + ~AR9170_USB_EP_OUT_STALL); +} + static inline void usb_structure_check(void) { BUILD_BUG_ON(sizeof(struct usb_config_descriptor) != USB_DT_CONFIG_SIZE);