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
d22abc20
Commit
d22abc20
authored
Oct 19, 2009
by
Charles Davis
Committed by
Alexandre Julliard
Oct 20, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Partially implement CDROM_GetControl() on Mac OS.
Only the speed is returned.
parent
122ed40c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
3 deletions
+13
-3
cdrom.c
dlls/ntdll/cdrom.c
+13
-3
No files found.
dlls/ntdll/cdrom.c
View file @
d22abc20
...
...
@@ -670,10 +670,20 @@ static NTSTATUS CDROM_GetStatusCode(int io)
* CDROM_GetControl
*
*/
static
NTSTATUS
CDROM_GetControl
(
int
dev
,
CDROM_AUDIO_CONTROL
*
cac
)
static
NTSTATUS
CDROM_GetControl
(
int
dev
,
int
fd
,
CDROM_AUDIO_CONTROL
*
cac
)
{
cac
->
LbaFormat
=
0
;
/* FIXME */
#ifdef __APPLE__
uint16_t
speed
;
int
io
=
ioctl
(
fd
,
DKIOCCDGETSPEED
,
&
speed
);
if
(
io
!=
0
)
return
CDROM_GetStatusCode
(
io
);
/* DKIOCCDGETSPEED returns the speed in kilobytes per second,
* so convert to logical blocks (assumed to be ~2 KB).
*/
cac
->
LogicalBlocksPerSecond
=
speed
/
2
;
#else
cac
->
LogicalBlocksPerSecond
=
1
;
/* FIXME */
#endif
cac
->
LbaFormat
=
0
;
/* FIXME */
return
STATUS_NOT_SUPPORTED
;
}
...
...
@@ -2762,7 +2772,7 @@ NTSTATUS CDROM_DeviceIoControl(HANDLE hDevice,
sz
=
sizeof
(
CDROM_AUDIO_CONTROL
);
if
(
lpInBuffer
!=
NULL
||
nInBufferSize
!=
0
)
status
=
STATUS_INVALID_PARAMETER
;
else
if
(
nOutBufferSize
<
sz
)
status
=
STATUS_BUFFER_TOO_SMALL
;
else
status
=
CDROM_GetControl
(
dev
,
lpOutBuffer
);
else
status
=
CDROM_GetControl
(
dev
,
fd
,
lpOutBuffer
);
break
;
case
IOCTL_CDROM_GET_DRIVE_GEOMETRY
:
...
...
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