Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
f37ae29b
Commit
f37ae29b
authored
Sep 20, 2021
by
Rémi Bernon
Committed by
Alexandre Julliard
Sep 20, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winebus.sys: Use WINEBUS\ as device id prefix for all buses.
Signed-off-by:
Rémi Bernon
<
rbernon@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
8fb10882
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
4 deletions
+8
-4
main.c
dlls/winebus.sys/main.c
+8
-4
No files found.
dlls/winebus.sys/main.c
View file @
f37ae29b
...
...
@@ -209,15 +209,19 @@ static WCHAR *get_instance_id(DEVICE_OBJECT *device)
static
WCHAR
*
get_device_id
(
DEVICE_OBJECT
*
device
)
{
static
const
WCHAR
input_format
[]
=
L"&MI_%02u"
;
static
const
WCHAR
format
[]
=
L"%s
\\
vid_%04x&pid_%04x
"
;
static
const
WCHAR
winebus_format
[]
=
L"WINEBUS
\\
VID_%04X&PID_%04X
"
;
struct
device_extension
*
ext
=
(
struct
device_extension
*
)
device
->
DeviceExtension
;
DWORD
pos
=
0
,
len
=
wcslen
(
ext
->
desc
.
busid
)
+
34
;
DWORD
pos
=
0
,
len
=
0
,
input_len
=
0
,
winebus_len
=
25
;
WCHAR
*
dst
;
if
(
ext
->
desc
.
input
!=
-
1
)
input_len
=
14
;
len
+=
winebus_len
+
input_len
+
1
;
if
((
dst
=
ExAllocatePool
(
PagedPool
,
len
*
sizeof
(
WCHAR
))))
{
pos
+=
swprintf
(
dst
+
pos
,
len
-
pos
,
format
,
ext
->
desc
.
busid
,
ext
->
desc
.
vid
,
ext
->
desc
.
pid
);
if
(
ext
->
desc
.
input
!=
-
1
)
pos
+=
swprintf
(
dst
+
pos
,
len
-
pos
,
input_format
,
ext
->
desc
.
input
);
pos
+=
swprintf
(
dst
+
pos
,
len
-
pos
,
winebus_format
,
ext
->
desc
.
vid
,
ext
->
desc
.
pid
);
if
(
input_len
)
pos
+=
swprintf
(
dst
+
pos
,
len
-
pos
,
input_format
,
ext
->
desc
.
input
);
}
return
dst
;
...
...
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