Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
8a88fa5d
Commit
8a88fa5d
authored
Oct 29, 2002
by
Greg Kroah-Hartman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
USB: drivers/isdn/hisax fixups due to USB structure changes.
parent
c632fbc3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
17 deletions
+17
-17
drivers/isdn/hisax/st5481_b.c
drivers/isdn/hisax/st5481_b.c
+4
-4
drivers/isdn/hisax/st5481_d.c
drivers/isdn/hisax/st5481_d.c
+4
-4
drivers/isdn/hisax/st5481_usb.c
drivers/isdn/hisax/st5481_usb.c
+9
-9
No files found.
drivers/isdn/hisax/st5481_b.c
View file @
8a88fa5d
...
...
@@ -253,8 +253,8 @@ static void st5481B_mode(struct st5481_bcs *bcs, int mode)
static
int
__devinit
st5481_setup_b_out
(
struct
st5481_bcs
*
bcs
)
{
struct
usb_device
*
dev
=
bcs
->
adapter
->
usb_dev
;
struct
usb_
interface_descriptor
*
altsetting
;
struct
usb_
endpoint_descriptor
*
endpoint
;
struct
usb_
host_interface
*
altsetting
;
struct
usb_
host_endpoint
*
endpoint
;
struct
st5481_b_out
*
b_out
=
&
bcs
->
b_out
;
DBG
(
4
,
""
);
...
...
@@ -265,11 +265,11 @@ static int __devinit st5481_setup_b_out(struct st5481_bcs *bcs)
endpoint
=
&
altsetting
->
endpoint
[
EP_B1_OUT
-
1
+
bcs
->
channel
*
2
];
DBG
(
4
,
"endpoint address=%02x,packet size=%d"
,
endpoint
->
bEndpointAddress
,
endpoint
->
wMaxPacketSize
);
endpoint
->
desc
.
bEndpointAddress
,
endpoint
->
desc
.
wMaxPacketSize
);
// Allocate memory for 8000bytes/sec + extra bytes if underrun
return
st5481_setup_isocpipes
(
b_out
->
urb
,
dev
,
usb_sndisocpipe
(
dev
,
endpoint
->
bEndpointAddress
),
usb_sndisocpipe
(
dev
,
endpoint
->
desc
.
bEndpointAddress
),
NUM_ISO_PACKETS_B
,
SIZE_ISO_PACKETS_B_OUT
,
NUM_ISO_PACKETS_B
*
SIZE_ISO_PACKETS_B_OUT
+
B_FLOW_ADJUST
,
usb_b_out_complete
,
bcs
);
...
...
drivers/isdn/hisax/st5481_d.c
View file @
8a88fa5d
...
...
@@ -652,8 +652,8 @@ static void ph_disconnect(struct st5481_adapter *adapter)
static
int
__devinit
st5481_setup_d_out
(
struct
st5481_adapter
*
adapter
)
{
struct
usb_device
*
dev
=
adapter
->
usb_dev
;
struct
usb_
interface_descriptor
*
altsetting
;
struct
usb_
endpoint_descriptor
*
endpoint
;
struct
usb_
host_interface
*
altsetting
;
struct
usb_
host_endpoint
*
endpoint
;
struct
st5481_d_out
*
d_out
=
&
adapter
->
d_out
;
DBG
(
2
,
""
);
...
...
@@ -664,10 +664,10 @@ static int __devinit st5481_setup_d_out(struct st5481_adapter *adapter)
endpoint
=
&
altsetting
->
endpoint
[
EP_D_OUT
-
1
];
DBG
(
2
,
"endpoint address=%02x,packet size=%d"
,
endpoint
->
bEndpointAddress
,
endpoint
->
wMaxPacketSize
);
endpoint
->
desc
.
bEndpointAddress
,
endpoint
->
desc
.
wMaxPacketSize
);
return
st5481_setup_isocpipes
(
d_out
->
urb
,
dev
,
usb_sndisocpipe
(
dev
,
endpoint
->
bEndpointAddress
),
usb_sndisocpipe
(
dev
,
endpoint
->
desc
.
bEndpointAddress
),
NUM_ISO_PACKETS_D
,
SIZE_ISO_PACKETS_D_OUT
,
NUM_ISO_PACKETS_D
*
SIZE_ISO_PACKETS_D_OUT
,
usb_d_out_complete
,
adapter
);
...
...
drivers/isdn/hisax/st5481_usb.c
View file @
8a88fa5d
...
...
@@ -244,15 +244,15 @@ int __devinit st5481_setup_usb(struct st5481_adapter *adapter)
struct
usb_device
*
dev
=
adapter
->
usb_dev
;
struct
st5481_ctrl
*
ctrl
=
&
adapter
->
ctrl
;
struct
st5481_intr
*
intr
=
&
adapter
->
intr
;
struct
usb_
interface_descriptor
*
altsetting
;
struct
usb_
endpoint_descriptor
*
endpoint
;
struct
usb_
host_interface
*
altsetting
;
struct
usb_
host_endpoint
*
endpoint
;
int
status
;
struct
urb
*
urb
;
u_char
*
buf
;
DBG
(
1
,
""
);
if
((
status
=
usb_set_configuration
(
dev
,
dev
->
config
[
0
].
bConfigurationValue
))
<
0
)
{
if
((
status
=
usb_set_configuration
(
dev
,
dev
->
config
[
0
].
desc
.
bConfigurationValue
))
<
0
)
{
WARN
(
"set_configuration failed,status=%d"
,
status
);
return
status
;
}
...
...
@@ -261,14 +261,14 @@ int __devinit st5481_setup_usb(struct st5481_adapter *adapter)
altsetting
=
&
(
dev
->
config
->
interface
[
0
].
altsetting
[
3
]);
// Check if the config is sane
if
(
altsetting
->
bNumEndpoints
!=
7
)
{
WARN
(
"expecting 7 got %d endpoints!"
,
altsetting
->
bNumEndpoints
);
if
(
altsetting
->
desc
.
bNumEndpoints
!=
7
)
{
WARN
(
"expecting 7 got %d endpoints!"
,
altsetting
->
desc
.
bNumEndpoints
);
return
-
EINVAL
;
}
// The descriptor is wrong for some early samples of the ST5481 chip
altsetting
->
endpoint
[
3
].
wMaxPacketSize
=
32
;
altsetting
->
endpoint
[
4
].
wMaxPacketSize
=
32
;
altsetting
->
endpoint
[
3
].
desc
.
wMaxPacketSize
=
32
;
altsetting
->
endpoint
[
4
].
desc
.
wMaxPacketSize
=
32
;
// Use alternative setting 3 on interface 0 to have 2B+D
if
((
status
=
usb_set_interface
(
dev
,
0
,
3
))
<
0
)
{
...
...
@@ -307,10 +307,10 @@ int __devinit st5481_setup_usb(struct st5481_adapter *adapter)
// Fill the interrupt URB
usb_fill_int_urb
(
urb
,
dev
,
usb_rcvintpipe
(
dev
,
endpoint
->
bEndpointAddress
),
usb_rcvintpipe
(
dev
,
endpoint
->
desc
.
bEndpointAddress
),
buf
,
INT_PKT_SIZE
,
usb_int_complete
,
adapter
,
endpoint
->
bInterval
);
endpoint
->
desc
.
bInterval
);
return
0
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment