VirtualBox

source: vbox/trunk/include/VBox/vmm/pdmusb.h@ 56954

Last change on this file since 56954 was 56291, checked in by vboxsync, 10 years ago

include: Updated (C) year.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 41.7 KB
Line 
1/** @file
2 * PDM - Pluggable Device Manager, USB Devices.
3 */
4
5/*
6 * Copyright (C) 2006-2015 Oracle Corporation
7 *
8 * This file is part of VirtualBox Open Source Edition (OSE), as
9 * available from http://www.virtualbox.org. This file is free software;
10 * you can redistribute it and/or modify it under the terms of the GNU
11 * General Public License (GPL) as published by the Free Software
12 * Foundation, in version 2 as it comes in the "COPYING" file of the
13 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
14 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
15 *
16 * The contents of this file may alternatively be used under the terms
17 * of the Common Development and Distribution License Version 1.0
18 * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
19 * VirtualBox OSE distribution, in which case the provisions of the
20 * CDDL are applicable instead of those of the GPL.
21 *
22 * You may elect to license modified versions of this file under the
23 * terms and conditions of either the GPL or the CDDL or both.
24 */
25
26#ifndef ___VBox_vmm_pdmusb_h
27#define ___VBox_vmm_pdmusb_h
28
29#include <VBox/vmm/pdmqueue.h>
30#include <VBox/vmm/pdmcritsect.h>
31#include <VBox/vmm/pdmthread.h>
32#include <VBox/vmm/pdmifs.h>
33#include <VBox/vmm/pdmcommon.h>
34#include <VBox/vmm/tm.h>
35#include <VBox/vmm/ssm.h>
36#include <VBox/vmm/cfgm.h>
37#include <VBox/vmm/dbgf.h>
38#include <VBox/vmm/mm.h>
39#include <VBox/err.h>
40#include <VBox/vusb.h>
41#include <iprt/stdarg.h>
42
43RT_C_DECLS_BEGIN
44
45/** @defgroup grp_pdm_usbdev The USB Devices API
46 * @ingroup grp_pdm
47 * @{
48 */
49
50
51/**
52 * A string entry for the USB descriptor cache.
53 */
54typedef struct PDMUSBDESCCACHESTRING
55{
56 /** The string index. */
57 uint8_t idx;
58 /** The UTF-8 representation of the string. */
59 const char *psz;
60} PDMUSBDESCCACHESTRING;
61/** Pointer to a const string entry. */
62typedef PDMUSBDESCCACHESTRING const *PCPDMUSBDESCCACHESTRING;
63
64
65/**
66 * A language entry for the USB descriptor cache.
67 */
68typedef struct PDMUSBDESCCACHELANG
69{
70 /** The language ID for the strings in this block. */
71 uint16_t idLang;
72 /** The number of strings in the array. */
73 uint16_t cStrings;
74 /** Pointer to an array of associated strings.
75 * This must be sorted in ascending order by string index as a binary lookup
76 * will be performed. */
77 PCPDMUSBDESCCACHESTRING paStrings;
78} PDMUSBDESCCACHELANG;
79/** Pointer to a const language entry. */
80typedef PDMUSBDESCCACHELANG const *PCPDMUSBDESCCACHELANG;
81
82
83/**
84 * USB descriptor cache.
85 *
86 * This structure is owned by the USB device but provided to the PDM/VUSB layer
87 * thru the PDMUSBREG::pfnGetDescriptorCache method. PDM/VUSB will use the
88 * information here to map addresses to endpoints, perform SET_CONFIGURATION
89 * requests, and optionally perform GET_DESCRIPTOR requests (see flag).
90 *
91 * Currently, only device and configuration descriptors are cached.
92 */
93typedef struct PDMUSBDESCCACHE
94{
95 /** USB device descriptor */
96 PCVUSBDESCDEVICE pDevice;
97 /** USB Descriptor arrays (pDev->bNumConfigurations) */
98 PCVUSBDESCCONFIGEX paConfigs;
99 /** Language IDs and their associated strings.
100 * This must be sorted in ascending order by language ID as a binary lookup
101 * will be used. */
102 PCPDMUSBDESCCACHELANG paLanguages;
103 /** The number of entries in the array pointed to by paLanguages. */
104 uint16_t cLanguages;
105 /** Use the cached descriptors for GET_DESCRIPTOR requests. */
106 bool fUseCachedDescriptors;
107 /** Use the cached string descriptors. */
108 bool fUseCachedStringsDescriptors;
109} PDMUSBDESCCACHE;
110/** Pointer to an USB descriptor cache. */
111typedef PDMUSBDESCCACHE *PPDMUSBDESCCACHE;
112/** Pointer to a const USB descriptor cache. */
113typedef const PDMUSBDESCCACHE *PCPDMUSBDESCCACHE;
114
115
116/** PDM Device Flags.
117 * @{ */
118/** A high-speed capable USB 2.0 device (also required to support full-speed). */
119#define PDM_USBREG_HIGHSPEED_CAPABLE RT_BIT(0)
120/** Indicates that the device implements the saved state handlers. */
121#define PDM_USBREG_SAVED_STATE_SUPPORTED RT_BIT(1)
122/** A SuperSpeed USB 3.0 device. */
123#define PDM_USBREG_SUPERSPEED_CAPABLE RT_BIT(2)
124/** @} */
125
126/** PDM USB Device Registration Structure,
127 *
128 * This structure is used when registering a device from VBoxUsbRegister() in HC Ring-3.
129 * The PDM will make use of this structure until the VM is destroyed.
130 */
131typedef struct PDMUSBREG
132{
133 /** Structure version. PDM_DEVREG_VERSION defines the current version. */
134 uint32_t u32Version;
135 /** Device name. */
136 char szName[32];
137 /** The description of the device. The UTF-8 string pointed to shall, like this structure,
138 * remain unchanged from registration till VM destruction. */
139 const char *pszDescription;
140
141 /** Flags, combination of the PDM_USBREG_FLAGS_* \#defines. */
142 RTUINT fFlags;
143 /** Maximum number of instances (per VM). */
144 RTUINT cMaxInstances;
145 /** Size of the instance data. */
146 RTUINT cbInstance;
147
148
149 /**
150 * Construct an USB device instance for a VM.
151 *
152 * @returns VBox status.
153 * @param pUsbIns The USB device instance data.
154 * If the registration structure is needed, it will be
155 * accessible thru pUsbDev->pReg.
156 * @param iInstance Instance number. Use this to figure out which registers
157 * and such to use. The instance number is also found in
158 * pUsbDev->iInstance, but since it's likely to be
159 * frequently used PDM passes it as parameter.
160 * @param pCfg Configuration node handle for the device. Use this to
161 * obtain the configuration of the device instance. It is
162 * also found in pUsbDev->pCfg, but since it is primary
163 * usage will in this function it is passed as a parameter.
164 * @param pCfgGlobal Handle to the global device configuration. Also found
165 * in pUsbDev->pCfgGlobal.
166 * @remarks This callback is required.
167 */
168 DECLR3CALLBACKMEMBER(int, pfnConstruct,(PPDMUSBINS pUsbIns, int iInstance, PCFGMNODE pCfg, PCFGMNODE pCfgGlobal));
169
170 /**
171 * Destruct an USB device instance.
172 *
173 * Most VM resources are freed by the VM. This callback is provided so that any non-VM
174 * resources can be freed correctly.
175 *
176 * This method will be called regardless of the pfnConstruct result to avoid
177 * complicated failure paths.
178 *
179 * @param pUsbIns The USB device instance data.
180 * @remarks Optional.
181 */
182 DECLR3CALLBACKMEMBER(void, pfnDestruct,(PPDMUSBINS pUsbIns));
183
184
185 /**
186 * Init complete notification.
187 *
188 * This can be done to do communication with other devices and other
189 * initialization which requires everything to be in place.
190 *
191 * @returns VBOX status code.
192 * @param pUsbIns The USB device instance data.
193 * @remarks Optional.
194 * @remarks Not called when hotplugged.
195 */
196 DECLR3CALLBACKMEMBER(int, pfnVMInitComplete,(PPDMUSBINS pUsbIns));
197
198 /**
199 * VM Power On notification.
200 *
201 * @returns VBox status.
202 * @param pUsbIns The USB device instance data.
203 * @remarks Optional.
204 */
205 DECLR3CALLBACKMEMBER(void, pfnVMPowerOn,(PPDMUSBINS pUsbIns));
206
207 /**
208 * VM Reset notification.
209 *
210 * @returns VBox status.
211 * @param pUsbIns The USB device instance data.
212 * @remarks Optional.
213 */
214 DECLR3CALLBACKMEMBER(void, pfnVMReset,(PPDMUSBINS pUsbIns));
215
216 /**
217 * VM Suspend notification.
218 *
219 * @returns VBox status.
220 * @param pUsbIns The USB device instance data.
221 * @remarks Optional.
222 */
223 DECLR3CALLBACKMEMBER(void, pfnVMSuspend,(PPDMUSBINS pUsbIns));
224
225 /**
226 * VM Resume notification.
227 *
228 * @returns VBox status.
229 * @param pUsbIns The USB device instance data.
230 * @remarks Optional.
231 */
232 DECLR3CALLBACKMEMBER(void, pfnVMResume,(PPDMUSBINS pUsbIns));
233
234 /**
235 * VM Power Off notification.
236 *
237 * This is only called when the VMR3PowerOff call is made on a running VM. This
238 * means that there is no notification if the VM was suspended before being
239 * powered of. There will also be no callback when hot plugging devices.
240 *
241 * @param pUsbIns The USB device instance data.
242 */
243 DECLR3CALLBACKMEMBER(void, pfnVMPowerOff,(PPDMUSBINS pUsbIns));
244
245 /**
246 * Called after the constructor when attaching a device at run time.
247 *
248 * This can be used to do tasks normally assigned to pfnInitComplete and/or pfnVMPowerOn.
249 *
250 * @returns VBox status.
251 * @param pUsbIns The USB device instance data.
252 * @remarks Optional.
253 */
254 DECLR3CALLBACKMEMBER(void, pfnHotPlugged,(PPDMUSBINS pUsbIns));
255
256 /**
257 * Called before the destructor when a device is unplugged at run time.
258 *
259 * This can be used to do tasks normally assigned to pfnVMSuspend and/or pfnVMPowerOff.
260 *
261 * @returns VBox status.
262 * @param pUsbIns The USB device instance data.
263 * @remarks Optional.
264 */
265 DECLR3CALLBACKMEMBER(void, pfnHotUnplugged,(PPDMUSBINS pUsbIns));
266 /**
267 * Driver Attach command.
268 *
269 * This is called to let the USB device attach to a driver for a specified LUN
270 * at runtime. This is not called during VM construction, the device constructor
271 * have to attach to all the available drivers.
272 *
273 * @returns VBox status code.
274 * @param pUsbIns The USB device instance data.
275 * @param iLUN The logical unit which is being detached.
276 * @param fFlags Flags, combination of the PDM_TACH_FLAGS_* \#defines.
277 * @remarks Optional.
278 */
279 DECLR3CALLBACKMEMBER(int, pfnDriverAttach,(PPDMUSBINS pUsbIns, unsigned iLUN, uint32_t fFlags));
280
281 /**
282 * Driver Detach notification.
283 *
284 * This is called when a driver is detaching itself from a LUN of the device.
285 * The device should adjust it's state to reflect this.
286 *
287 * @param pUsbIns The USB device instance data.
288 * @param iLUN The logical unit which is being detached.
289 * @param fFlags Flags, combination of the PDM_TACH_FLAGS_* \#defines.
290 * @remarks Optional.
291 */
292 DECLR3CALLBACKMEMBER(void, pfnDriverDetach,(PPDMUSBINS pUsbIns, unsigned iLUN, uint32_t fFlags));
293
294 /**
295 * Query the base interface of a logical unit.
296 *
297 * @returns VBOX status code.
298 * @param pUsbIns The USB device instance data.
299 * @param iLUN The logicial unit to query.
300 * @param ppBase Where to store the pointer to the base interface of the LUN.
301 * @remarks Optional.
302 */
303 DECLR3CALLBACKMEMBER(int, pfnQueryInterface,(PPDMUSBINS pUsbIns, unsigned iLUN, PPDMIBASE *ppBase));
304
305 /**
306 * Requests the USB device to reset.
307 *
308 * @returns VBox status code.
309 * @param pUsbIns The USB device instance.
310 * @param fResetOnLinux A hint to the usb proxy.
311 * Don't use this unless you're the linux proxy device.
312 * @thread Any thread.
313 * @remarks Optional.
314 */
315 DECLR3CALLBACKMEMBER(int, pfnUsbReset,(PPDMUSBINS pUsbIns, bool fResetOnLinux));
316
317 /**
318 * Query device and configuration descriptors for the caching and servicing
319 * relevant GET_DESCRIPTOR requests.
320 *
321 * @returns Pointer to the descriptor cache (read-only).
322 * @param pUsbIns The USB device instance.
323 * @remarks Mandatory.
324 */
325 DECLR3CALLBACKMEMBER(PCPDMUSBDESCCACHE, pfnUsbGetDescriptorCache,(PPDMUSBINS pUsbIns));
326
327 /**
328 * SET_CONFIGURATION request.
329 *
330 * @returns VBox status code.
331 * @param pUsbIns The USB device instance.
332 * @param bConfigurationValue The bConfigurationValue of the new configuration.
333 * @param pvOldCfgDesc Internal - for the device proxy.
334 * @param pvOldIfState Internal - for the device proxy.
335 * @param pvNewCfgDesc Internal - for the device proxy.
336 * @remarks Optional.
337 */
338 DECLR3CALLBACKMEMBER(int, pfnUsbSetConfiguration,(PPDMUSBINS pUsbIns, uint8_t bConfigurationValue,
339 const void *pvOldCfgDesc, const void *pvOldIfState, const void *pvNewCfgDesc));
340
341 /**
342 * SET_INTERFACE request.
343 *
344 * @returns VBox status code.
345 * @param pUsbIns The USB device instance.
346 * @param bInterfaceNumber The interface number.
347 * @param bAlternateSetting The alternate setting.
348 * @remarks Optional.
349 */
350 DECLR3CALLBACKMEMBER(int, pfnUsbSetInterface,(PPDMUSBINS pUsbIns, uint8_t bInterfaceNumber, uint8_t bAlternateSetting));
351
352 /**
353 * Clears the halted state of an endpoint. (Optional)
354 *
355 * This called when VUSB sees a CLEAR_FEATURE(ENDPOINT_HALT) on request
356 * on the zero pipe.
357 *
358 * @returns VBox status code.
359 * @param pUsbIns The USB device instance.
360 * @param uEndpoint The endpoint to clear.
361 * @remarks Optional.
362 */
363 DECLR3CALLBACKMEMBER(int, pfnUsbClearHaltedEndpoint,(PPDMUSBINS pUsbIns, unsigned uEndpoint));
364
365 /**
366 * Allocates an URB.
367 *
368 * This can be used to make use of shared user/kernel mode buffers.
369 *
370 * @returns VBox status code.
371 * @param pUsbIns The USB device instance.
372 * @param cbData The size of the data buffer.
373 * @param cTds The number of TDs.
374 * @param enmType The type of URB.
375 * @param ppUrb Where to store the allocated URB.
376 * @remarks Optional.
377 * @remarks Not implemented yet.
378 */
379 DECLR3CALLBACKMEMBER(int, pfnUrbNew,(PPDMUSBINS pUsbIns, size_t cbData, size_t cTds, VUSBXFERTYPE enmType, PVUSBURB *ppUrb));
380
381 /**
382 * Queues an URB for processing.
383 *
384 * @returns VBox status code.
385 * @retval VINF_SUCCESS on success.
386 * @retval VERR_VUSB_DEVICE_NOT_ATTACHED if the device has been disconnected.
387 * @retval VERR_VUSB_FAILED_TO_QUEUE_URB as a general failure kind of thing.
388 * @retval TBD - document new stuff!
389 *
390 * @param pUsbIns The USB device instance.
391 * @param pUrb The URB to process.
392 * @remarks Mandatory.
393 */
394 DECLR3CALLBACKMEMBER(int, pfnUrbQueue,(PPDMUSBINS pUsbIns, PVUSBURB pUrb));
395
396 /**
397 * Cancels an URB.
398 *
399 * @returns VBox status code.
400 * @param pUsbIns The USB device instance.
401 * @param pUrb The URB to cancel.
402 * @remarks Mandatory.
403 */
404 DECLR3CALLBACKMEMBER(int, pfnUrbCancel,(PPDMUSBINS pUsbIns, PVUSBURB pUrb));
405
406 /**
407 * Reaps an URB.
408 *
409 * @returns A ripe URB, NULL if none.
410 * @param pUsbIns The USB device instance.
411 * @param cMillies How log to wait for an URB to become ripe.
412 * @remarks Mandatory.
413 */
414 DECLR3CALLBACKMEMBER(PVUSBURB, pfnUrbReap,(PPDMUSBINS pUsbIns, RTMSINTERVAL cMillies));
415
416 /**
417 * Wakes a thread waiting in pfnUrbReap.
418 *
419 * @returns VBox status code.
420 * @param pUsbIns The USB device instance.
421 */
422 DECLR3CALLBACKMEMBER(int, pfnWakeup,(PPDMUSBINS pUsbIns));
423
424 /** Just some init precaution. Must be set to PDM_USBREG_VERSION. */
425 uint32_t u32TheEnd;
426} PDMUSBREG;
427/** Pointer to a PDM USB Device Structure. */
428typedef PDMUSBREG *PPDMUSBREG;
429/** Const pointer to a PDM USB Device Structure. */
430typedef PDMUSBREG const *PCPDMUSBREG;
431
432/** Current USBREG version number. */
433#define PDM_USBREG_VERSION PDM_VERSION_MAKE(0xeeff, 1, 0)
434
435/** PDM USB Device Flags.
436 * @{ */
437/* none yet */
438/** @} */
439
440
441#ifdef IN_RING3
442
443/**
444 * PDM USB Device API.
445 */
446typedef struct PDMUSBHLP
447{
448 /** Structure version. PDM_USBHLP_VERSION defines the current version. */
449 uint32_t u32Version;
450
451 /**
452 * Attaches a driver (chain) to the USB device.
453 *
454 * The first call for a LUN this will serve as a registration of the LUN. The pBaseInterface and
455 * the pszDesc string will be registered with that LUN and kept around for PDMR3QueryUSBDeviceLun().
456 *
457 * @returns VBox status code.
458 * @param pUsbIns The USB device instance.
459 * @param iLun The logical unit to attach.
460 * @param pBaseInterface Pointer to the base interface for that LUN. (device side / down)
461 * @param ppBaseInterface Where to store the pointer to the base interface. (driver side / up)
462 * @param pszDesc Pointer to a string describing the LUN. This string must remain valid
463 * for the live of the device instance.
464 */
465 DECLR3CALLBACKMEMBER(int, pfnDriverAttach,(PPDMUSBINS pUsbIns, RTUINT iLun, PPDMIBASE pBaseInterface, PPDMIBASE *ppBaseInterface, const char *pszDesc));
466
467 /**
468 * Assert that the current thread is the emulation thread.
469 *
470 * @returns True if correct.
471 * @returns False if wrong.
472 * @param pUsbIns The USB device instance.
473 * @param pszFile Filename of the assertion location.
474 * @param iLine Linenumber of the assertion location.
475 * @param pszFunction Function of the assertion location.
476 */
477 DECLR3CALLBACKMEMBER(bool, pfnAssertEMT,(PPDMUSBINS pUsbIns, const char *pszFile, unsigned iLine, const char *pszFunction));
478
479 /**
480 * Assert that the current thread is NOT the emulation thread.
481 *
482 * @returns True if correct.
483 * @returns False if wrong.
484 * @param pUsbIns The USB device instance.
485 * @param pszFile Filename of the assertion location.
486 * @param iLine Linenumber of the assertion location.
487 * @param pszFunction Function of the assertion location.
488 */
489 DECLR3CALLBACKMEMBER(bool, pfnAssertOther,(PPDMUSBINS pUsbIns, const char *pszFile, unsigned iLine, const char *pszFunction));
490
491 /**
492 * Stops the VM and enters the debugger to look at the guest state.
493 *
494 * Use the PDMUsbDBGFStop() inline function with the RT_SRC_POS macro instead of
495 * invoking this function directly.
496 *
497 * @returns VBox status code which must be passed up to the VMM.
498 * @param pUsbIns The USB device instance.
499 * @param pszFile Filename of the assertion location.
500 * @param iLine The linenumber of the assertion location.
501 * @param pszFunction Function of the assertion location.
502 * @param pszFormat Message. (optional)
503 * @param va Message parameters.
504 */
505 DECLR3CALLBACKMEMBER(int, pfnDBGFStopV,(PPDMUSBINS pUsbIns, const char *pszFile, unsigned iLine, const char *pszFunction, const char *pszFormat, va_list va));
506
507 /**
508 * Register a info handler with DBGF,
509 *
510 * @returns VBox status code.
511 * @param pUsbIns The USB device instance.
512 * @param pszName The identifier of the info.
513 * @param pszDesc The description of the info and any arguments the handler may take.
514 * @param pfnHandler The handler function to be called to display the info.
515 */
516 DECLR3CALLBACKMEMBER(int, pfnDBGFInfoRegister,(PPDMUSBINS pUsbIns, const char *pszName, const char *pszDesc, PFNDBGFHANDLERUSB pfnHandler));
517
518 /**
519 * Allocate memory which is associated with current VM instance
520 * and automatically freed on it's destruction.
521 *
522 * @returns Pointer to allocated memory. The memory is *NOT* zero-ed.
523 * @param pUsbIns The USB device instance.
524 * @param cb Number of bytes to allocate.
525 */
526 DECLR3CALLBACKMEMBER(void *, pfnMMHeapAlloc,(PPDMUSBINS pUsbIns, size_t cb));
527
528 /**
529 * Allocate memory which is associated with current VM instance
530 * and automatically freed on it's destruction. The memory is ZEROed.
531 *
532 * @returns Pointer to allocated memory. The memory is *NOT* zero-ed.
533 * @param pUsbIns The USB device instance.
534 * @param cb Number of bytes to allocate.
535 */
536 DECLR3CALLBACKMEMBER(void *, pfnMMHeapAllocZ,(PPDMUSBINS pUsbIns, size_t cb));
537
538 /**
539 * Create a queue.
540 *
541 * @returns VBox status code.
542 * @param pUsbIns The USB device instance.
543 * @param cbItem Size a queue item.
544 * @param cItems Number of items in the queue.
545 * @param cMilliesInterval Number of milliseconds between polling the queue.
546 * If 0 then the emulation thread will be notified whenever an item arrives.
547 * @param pfnCallback The consumer function.
548 * @param pszName The queue base name. The instance number will be
549 * appended automatically.
550 * @param ppQueue Where to store the queue handle on success.
551 * @thread The emulation thread.
552 */
553 DECLR3CALLBACKMEMBER(int, pfnPDMQueueCreate,(PPDMUSBINS pUsbIns, RTUINT cbItem, RTUINT cItems, uint32_t cMilliesInterval,
554 PFNPDMQUEUEUSB pfnCallback, const char *pszName, PPDMQUEUE *ppQueue));
555
556 /**
557 * Register a save state data unit.
558 *
559 * @returns VBox status.
560 * @param pUsbIns The USB device instance.
561 * @param uVersion Data layout version number.
562 * @param cbGuess The approximate amount of data in the unit.
563 * Only for progress indicators.
564 *
565 * @param pfnLivePrep Prepare live save callback, optional.
566 * @param pfnLiveExec Execute live save callback, optional.
567 * @param pfnLiveVote Vote live save callback, optional.
568 *
569 * @param pfnSavePrep Prepare save callback, optional.
570 * @param pfnSaveExec Execute save callback, optional.
571 * @param pfnSaveDone Done save callback, optional.
572 *
573 * @param pfnLoadPrep Prepare load callback, optional.
574 * @param pfnLoadExec Execute load callback, optional.
575 * @param pfnLoadDone Done load callback, optional.
576 */
577 DECLR3CALLBACKMEMBER(int, pfnSSMRegister,(PPDMUSBINS pUsbIns, uint32_t uVersion, size_t cbGuess,
578 PFNSSMUSBLIVEPREP pfnLivePrep, PFNSSMUSBLIVEEXEC pfnLiveExec, PFNSSMUSBLIVEVOTE pfnLiveVote,
579 PFNSSMUSBSAVEPREP pfnSavePrep, PFNSSMUSBSAVEEXEC pfnSaveExec, PFNSSMUSBSAVEDONE pfnSaveDone,
580 PFNSSMUSBLOADPREP pfnLoadPrep, PFNSSMUSBLOADEXEC pfnLoadExec, PFNSSMUSBLOADDONE pfnLoadDone));
581
582 /**
583 * Register a STAM sample.
584 *
585 * Use the PDMUsbHlpSTAMRegister wrapper.
586 *
587 * @returns VBox status.
588 * @param pUsbIns The USB device instance.
589 * @param pvSample Pointer to the sample.
590 * @param enmType Sample type. This indicates what pvSample is pointing at.
591 * @param enmVisibility Visibility type specifying whether unused statistics should be visible or not.
592 * @param enmUnit Sample unit.
593 * @param pszDesc Sample description.
594 * @param pszName The sample name format string.
595 * @param va Arguments to the format string.
596 */
597 DECLR3CALLBACKMEMBER(void, pfnSTAMRegisterV,(PPDMUSBINS pUsbIns, void *pvSample, STAMTYPE enmType, STAMVISIBILITY enmVisibility,
598 STAMUNIT enmUnit, const char *pszDesc, const char *pszName, va_list va));
599
600 /**
601 * Creates a timer.
602 *
603 * @returns VBox status.
604 * @param pUsbIns The USB device instance.
605 * @param enmClock The clock to use on this timer.
606 * @param pfnCallback Callback function.
607 * @param pvUser User argument for the callback.
608 * @param fFlags Flags, see TMTIMER_FLAGS_*.
609 * @param pszDesc Pointer to description string which must stay around
610 * until the timer is fully destroyed (i.e. a bit after TMTimerDestroy()).
611 * @param ppTimer Where to store the timer on success.
612 */
613 DECLR3CALLBACKMEMBER(int, pfnTMTimerCreate,(PPDMUSBINS pUsbIns, TMCLOCK enmClock, PFNTMTIMERUSB pfnCallback, void *pvUser,
614 uint32_t fFlags, const char *pszDesc, PPTMTIMERR3 ppTimer));
615
616 /**
617 * Set the VM error message
618 *
619 * @returns rc.
620 * @param pUsbIns The USB device instance.
621 * @param rc VBox status code.
622 * @param RT_SRC_POS_DECL Use RT_SRC_POS.
623 * @param pszFormat Error message format string.
624 * @param va Error message arguments.
625 */
626 DECLR3CALLBACKMEMBER(int, pfnVMSetErrorV,(PPDMUSBINS pUsbIns, int rc, RT_SRC_POS_DECL, const char *pszFormat, va_list va));
627
628 /**
629 * Set the VM runtime error message
630 *
631 * @returns VBox status code.
632 * @param pUsbIns The USB device instance.
633 * @param fFlags The action flags. See VMSETRTERR_FLAGS_*.
634 * @param pszErrorId Error ID string.
635 * @param pszFormat Error message format string.
636 * @param va Error message arguments.
637 */
638 DECLR3CALLBACKMEMBER(int, pfnVMSetRuntimeErrorV,(PPDMUSBINS pUsbIns, uint32_t fFlags, const char *pszErrorId, const char *pszFormat, va_list va));
639
640 /**
641 * Gets the VM state.
642 *
643 * @returns VM state.
644 * @param pUsbIns The USB device instance.
645 * @thread Any thread (just keep in mind that it's volatile info).
646 */
647 DECLR3CALLBACKMEMBER(VMSTATE, pfnVMState, (PPDMUSBINS pUsbIns));
648
649 /**
650 * Creates a PDM thread.
651 *
652 * This differs from the RTThreadCreate() API in that PDM takes care of suspending,
653 * resuming, and destroying the thread as the VM state changes.
654 *
655 * @returns VBox status code.
656 * @param pDevIns The device instance.
657 * @param ppThread Where to store the thread 'handle'.
658 * @param pvUser The user argument to the thread function.
659 * @param pfnThread The thread function.
660 * @param pfnWakeup The wakup callback. This is called on the EMT
661 * thread when a state change is pending.
662 * @param cbStack See RTThreadCreate.
663 * @param enmType See RTThreadCreate.
664 * @param pszName See RTThreadCreate.
665 */
666 DECLR3CALLBACKMEMBER(int, pfnThreadCreate,(PPDMUSBINS pUsbIns, PPPDMTHREAD ppThread, void *pvUser, PFNPDMTHREADUSB pfnThread,
667 PFNPDMTHREADWAKEUPUSB pfnWakeup, size_t cbStack, RTTHREADTYPE enmType, const char *pszName));
668
669 /**
670 * Set up asynchronous handling of a suspend, reset or power off notification.
671 *
672 * This shall only be called when getting the notification. It must be called
673 * for each one.
674 *
675 * @returns VBox status code.
676 * @param pUSBIns The USB device instance.
677 * @param pfnAsyncNotify The callback.
678 * @thread EMT(0)
679 */
680 DECLR3CALLBACKMEMBER(int, pfnSetAsyncNotification, (PPDMUSBINS pUSbIns, PFNPDMUSBASYNCNOTIFY pfnAsyncNotify));
681
682 /**
683 * Notify EMT(0) that the device has completed the asynchronous notification
684 * handling.
685 *
686 * This can be called at any time, spurious calls will simply be ignored.
687 *
688 * @param pUSBIns The USB device instance.
689 * @thread Any
690 */
691 DECLR3CALLBACKMEMBER(void, pfnAsyncNotificationCompleted, (PPDMUSBINS pUsbIns));
692
693 /**
694 * Gets the reason for the most recent VM suspend.
695 *
696 * @returns The suspend reason. VMSUSPENDREASON_INVALID is returned if no
697 * suspend has been made or if the pUsbIns is invalid.
698 * @param pUsbIns The driver instance.
699 */
700 DECLR3CALLBACKMEMBER(VMSUSPENDREASON, pfnVMGetSuspendReason,(PPDMUSBINS pUsbIns));
701
702 /**
703 * Gets the reason for the most recent VM resume.
704 *
705 * @returns The resume reason. VMRESUMEREASON_INVALID is returned if no
706 * resume has been made or if the pUsbIns is invalid.
707 * @param pUsbIns The driver instance.
708 */
709 DECLR3CALLBACKMEMBER(VMRESUMEREASON, pfnVMGetResumeReason,(PPDMUSBINS pUsbIns));
710
711 /** @name Space reserved for minor interface changes.
712 * @{ */
713 DECLR3CALLBACKMEMBER(void, pfnReserved0,(PPDMUSBINS pUsbIns));
714 DECLR3CALLBACKMEMBER(void, pfnReserved1,(PPDMUSBINS pUsbIns));
715 DECLR3CALLBACKMEMBER(void, pfnReserved2,(PPDMUSBINS pUsbIns));
716 DECLR3CALLBACKMEMBER(void, pfnReserved3,(PPDMUSBINS pUsbIns));
717 DECLR3CALLBACKMEMBER(void, pfnReserved4,(PPDMUSBINS pUsbIns));
718 DECLR3CALLBACKMEMBER(void, pfnReserved5,(PPDMUSBINS pUsbIns));
719 DECLR3CALLBACKMEMBER(void, pfnReserved6,(PPDMUSBINS pUsbIns));
720 DECLR3CALLBACKMEMBER(void, pfnReserved7,(PPDMUSBINS pUsbIns));
721 DECLR3CALLBACKMEMBER(void, pfnReserved8,(PPDMUSBINS pUsbIns));
722 DECLR3CALLBACKMEMBER(void, pfnReserved9,(PPDMUSBINS pUsbIns));
723 /** @} */
724
725 /** Just a safety precaution. */
726 uint32_t u32TheEnd;
727} PDMUSBHLP;
728/** Pointer PDM USB Device API. */
729typedef PDMUSBHLP *PPDMUSBHLP;
730/** Pointer const PDM USB Device API. */
731typedef const PDMUSBHLP *PCPDMUSBHLP;
732
733/** Current USBHLP version number. */
734#define PDM_USBHLP_VERSION PDM_VERSION_MAKE(0xeefe, 3, 0)
735
736#endif /* IN_RING3 */
737
738/**
739 * PDM USB Device Instance.
740 */
741typedef struct PDMUSBINS
742{
743 /** Structure version. PDM_USBINS_VERSION defines the current version. */
744 uint32_t u32Version;
745 /** USB device instance number. */
746 uint32_t iInstance;
747 /** The base interface of the device.
748 * The device constructor initializes this if it has any device level
749 * interfaces to export. To obtain this interface call PDMR3QueryUSBDevice(). */
750 PDMIBASE IBase;
751#if HC_ARCH_BITS == 32
752 uint32_t u32Alignment; /**< Alignment padding. */
753#endif
754
755 /** Internal data. */
756 union
757 {
758#ifdef PDMUSBINSINT_DECLARED
759 PDMUSBINSINT s;
760#endif
761 uint8_t padding[HC_ARCH_BITS == 32 ? 96 : 128];
762 } Internal;
763
764 /** Pointer the PDM USB Device API. */
765 R3PTRTYPE(PCPDMUSBHLP) pHlpR3;
766 /** Pointer to the USB device registration structure. */
767 R3PTRTYPE(PCPDMUSBREG) pReg;
768 /** Configuration handle. */
769 R3PTRTYPE(PCFGMNODE) pCfg;
770 /** The (device) global configuration handle. */
771 R3PTRTYPE(PCFGMNODE) pCfgGlobal;
772 /** Pointer to device instance data. */
773 R3PTRTYPE(void *) pvInstanceDataR3;
774 /** Pointer to the VUSB Device structure.
775 * Internal to VUSB, don't touch.
776 * @todo Moved this to PDMUSBINSINT. */
777 R3PTRTYPE(void *) pvVUsbDev2;
778 /** Device name for using when logging.
779 * The constructor sets this and the destructor frees it. */
780 R3PTRTYPE(char *) pszName;
781 /** Tracing indicator. */
782 uint32_t fTracing;
783 /** The tracing ID of this device. */
784 uint32_t idTracing;
785 /** The port/device speed. HCs and emulated devices need to know. */
786 VUSBSPEED enmSpeed;
787
788 /** Padding to make achInstanceData aligned at 32 byte boundary. */
789 uint32_t au32Padding[HC_ARCH_BITS == 32 ? 2 : 3];
790
791 /** Device instance data. The size of this area is defined
792 * in the PDMUSBREG::cbInstanceData field. */
793 char achInstanceData[8];
794} PDMUSBINS;
795
796/** Current USBINS version number. */
797#define PDM_USBINS_VERSION PDM_VERSION_MAKE(0xeefd, 3, 0)
798
799/**
800 * Checks the structure versions of the USB device instance and USB device
801 * helpers, returning if they are incompatible.
802 *
803 * This is for use in the constructor.
804 *
805 * @param pUsbIns The USB device instance pointer.
806 */
807#define PDMUSB_CHECK_VERSIONS_RETURN(pUsbIns) \
808 do \
809 { \
810 PPDMUSBINS pUsbInsTypeCheck = (pUsbIns); NOREF(pUsbInsTypeCheck); \
811 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->u32Version, PDM_USBINS_VERSION), \
812 ("DevIns=%#x mine=%#x\n", (pUsbIns)->u32Version, PDM_USBINS_VERSION), \
813 VERR_PDM_USBINS_VERSION_MISMATCH); \
814 AssertLogRelMsgReturn(PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->pHlpR3->u32Version, PDM_USBHLP_VERSION), \
815 ("DevHlp=%#x mine=%#x\n", (pUsbIns)->pHlpR3->u32Version, PDM_USBHLP_VERSION), \
816 VERR_PDM_USBHLPR3_VERSION_MISMATCH); \
817 } while (0)
818
819/**
820 * Quietly checks the structure versions of the USB device instance and
821 * USB device helpers, returning if they are incompatible.
822 *
823 * This is for use in the destructor.
824 *
825 * @param pUsbIns The USB device instance pointer.
826 */
827#define PDMUSB_CHECK_VERSIONS_RETURN_QUIET(pUsbIns) \
828 do \
829 { \
830 PPDMUSBINS pUsbInsTypeCheck = (pUsbIns); NOREF(pUsbInsTypeCheck); \
831 if (RT_LIKELY(PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->u32Version, PDM_USBINS_VERSION) )) \
832 { /* likely */ } else return VERR_PDM_USBINS_VERSION_MISMATCH; \
833 if (RT_LIKELY(PDM_VERSION_ARE_COMPATIBLE((pUsbIns)->pHlpR3->u32Version, PDM_USBHLPR3_VERSION) )) \
834 { /* likely */ } else return VERR_PDM_USBHLPR3_VERSION_MISMATCH; \
835 } while (0)
836
837
838/** Converts a pointer to the PDMUSBINS::IBase to a pointer to PDMUSBINS. */
839#define PDMIBASE_2_PDMUSB(pInterface) ( (PPDMUSBINS)((char *)(pInterface) - RT_OFFSETOF(PDMUSBINS, IBase)) )
840
841
842/** @def PDMUSB_ASSERT_EMT
843 * Assert that the current thread is the emulation thread.
844 */
845#ifdef VBOX_STRICT
846# define PDMUSB_ASSERT_EMT(pUsbIns) pUsbIns->pHlpR3->pfnAssertEMT(pUsbIns, __FILE__, __LINE__, __FUNCTION__)
847#else
848# define PDMUSB_ASSERT_EMT(pUsbIns) do { } while (0)
849#endif
850
851/** @def PDMUSB_ASSERT_OTHER
852 * Assert that the current thread is NOT the emulation thread.
853 */
854#ifdef VBOX_STRICT
855# define PDMUSB_ASSERT_OTHER(pUsbIns) pUsbIns->pHlpR3->pfnAssertOther(pUsbIns, __FILE__, __LINE__, __FUNCTION__)
856#else
857# define PDMUSB_ASSERT_OTHER(pUsbIns) do { } while (0)
858#endif
859
860/** @def PDMUSB_SET_ERROR
861 * Set the VM error. See PDMUsbHlpVMSetError() for printf like message
862 * formatting.
863 */
864#define PDMUSB_SET_ERROR(pUsbIns, rc, pszError) \
865 PDMUsbHlpVMSetError(pUsbIns, rc, RT_SRC_POS, "%s", pszError)
866
867/** @def PDMUSB_SET_RUNTIME_ERROR
868 * Set the VM runtime error. See PDMUsbHlpVMSetRuntimeError() for printf like
869 * message formatting.
870 */
871#define PDMUSB_SET_RUNTIME_ERROR(pUsbIns, fFlags, pszErrorId, pszError) \
872 PDMUsbHlpVMSetRuntimeError(pUsbIns, fFlags, pszErrorId, "%s", pszError)
873
874
875#ifdef IN_RING3
876
877/**
878 * @copydoc PDMUSBHLP::pfnDriverAttach
879 */
880DECLINLINE(int) PDMUsbHlpDriverAttach(PPDMUSBINS pUsbIns, RTUINT iLun, PPDMIBASE pBaseInterface, PPDMIBASE *ppBaseInterface, const char *pszDesc)
881{
882 return pUsbIns->pHlpR3->pfnDriverAttach(pUsbIns, iLun, pBaseInterface, ppBaseInterface, pszDesc);
883}
884
885/**
886 * VBOX_STRICT wrapper for pHlpR3->pfnDBGFStopV.
887 *
888 * @returns VBox status code which must be passed up to the VMM.
889 * @param pUsbIns Device instance.
890 * @param RT_SRC_POS_DECL Use RT_SRC_POS.
891 * @param pszFormat Message. (optional)
892 * @param ... Message parameters.
893 */
894DECLINLINE(int) PDMUsbDBGFStop(PPDMUSBINS pUsbIns, RT_SRC_POS_DECL, const char *pszFormat, ...)
895{
896#ifdef VBOX_STRICT
897 int rc;
898 va_list va;
899 va_start(va, pszFormat);
900 rc = pUsbIns->pHlpR3->pfnDBGFStopV(pUsbIns, RT_SRC_POS_ARGS, pszFormat, va);
901 va_end(va);
902 return rc;
903#else
904 NOREF(pUsbIns);
905 NOREF(pszFile);
906 NOREF(iLine);
907 NOREF(pszFunction);
908 NOREF(pszFormat);
909 return VINF_SUCCESS;
910#endif
911}
912
913/**
914 * @copydoc PDMUSBHLP::pfnVMState
915 */
916DECLINLINE(VMSTATE) PDMUsbHlpVMState(PPDMUSBINS pUsbIns)
917{
918 return pUsbIns->pHlpR3->pfnVMState(pUsbIns);
919}
920
921/**
922 * @copydoc PDMUSBHLP::pfnThreadCreate
923 */
924DECLINLINE(int) PDMUsbHlpThreadCreate(PPDMUSBINS pUsbIns, PPPDMTHREAD ppThread, void *pvUser, PFNPDMTHREADUSB pfnThread,
925 PFNPDMTHREADWAKEUPUSB pfnWakeup, size_t cbStack, RTTHREADTYPE enmType, const char *pszName)
926{
927 return pUsbIns->pHlpR3->pfnThreadCreate(pUsbIns, ppThread, pvUser, pfnThread, pfnWakeup, cbStack, enmType, pszName);
928}
929
930
931/**
932 * @copydoc PDMUSBHLP::pfnSetAsyncNotification
933 */
934DECLINLINE(int) PDMUsbHlpSetAsyncNotification(PPDMUSBINS pUsbIns, PFNPDMUSBASYNCNOTIFY pfnAsyncNotify)
935{
936 return pUsbIns->pHlpR3->pfnSetAsyncNotification(pUsbIns, pfnAsyncNotify);
937}
938
939/**
940 * @copydoc PDMUSBHLP::pfnAsyncNotificationCompleted
941 */
942DECLINLINE(void) PDMUsbHlpAsyncNotificationCompleted(PPDMUSBINS pUsbIns)
943{
944 pUsbIns->pHlpR3->pfnAsyncNotificationCompleted(pUsbIns);
945}
946
947/**
948 * Set the VM error message
949 *
950 * @returns rc.
951 * @param pUsbIns The USB device instance.
952 * @param rc VBox status code.
953 * @param RT_SRC_POS_DECL Use RT_SRC_POS.
954 * @param pszFormat Error message format string.
955 * @param ... Error message arguments.
956 */
957DECLINLINE(int) PDMUsbHlpVMSetError(PPDMUSBINS pUsbIns, int rc, RT_SRC_POS_DECL, const char *pszFormat, ...)
958{
959 va_list va;
960 va_start(va, pszFormat);
961 rc = pUsbIns->pHlpR3->pfnVMSetErrorV(pUsbIns, rc, RT_SRC_POS_ARGS, pszFormat, va);
962 va_end(va);
963 return rc;
964}
965
966/**
967 * @copydoc PDMUSBHLP::pfnMMHeapAlloc
968 */
969DECLINLINE(void *) PDMUsbHlpMMHeapAlloc(PPDMUSBINS pUsbIns, size_t cb)
970{
971 return pUsbIns->pHlpR3->pfnMMHeapAlloc(pUsbIns, cb);
972}
973
974/**
975 * @copydoc PDMUSBHLP::pfnMMHeapAllocZ
976 */
977DECLINLINE(void *) PDMUsbHlpMMHeapAllocZ(PPDMUSBINS pUsbIns, size_t cb)
978{
979 return pUsbIns->pHlpR3->pfnMMHeapAllocZ(pUsbIns, cb);
980}
981
982/**
983 * Frees memory allocated by PDMUsbHlpMMHeapAlloc or PDMUsbHlpMMHeapAllocZ.
984 *
985 * @param pUsbIns The USB device instance.
986 * @param pv The memory to free. NULL is fine.
987 */
988DECLINLINE(void) PDMUsbHlpMMHeapFree(PPDMUSBINS pUsbIns, void *pv)
989{
990 NOREF(pUsbIns);
991 MMR3HeapFree(pv);
992}
993
994/**
995 * @copydoc PDMUSBHLP::pfnTMTimerCreate
996 */
997DECLINLINE(int) PDMUsbHlpTMTimerCreate(PPDMUSBINS pUsbIns, TMCLOCK enmClock, PFNTMTIMERUSB pfnCallback, void *pvUser,
998 uint32_t fFlags, const char *pszDesc, PPTMTIMERR3 ppTimer)
999{
1000 return pUsbIns->pHlpR3->pfnTMTimerCreate(pUsbIns, enmClock, pfnCallback, pvUser, fFlags, pszDesc, ppTimer);
1001}
1002
1003/**
1004 * @copydoc PDMUSBHLP::pfnSSMRegister
1005 */
1006DECLINLINE(int) PDMUsbHlpSSMRegister(PPDMUSBINS pUsbIns, uint32_t uVersion, size_t cbGuess,
1007 PFNSSMUSBLIVEPREP pfnLivePrep, PFNSSMUSBLIVEEXEC pfnLiveExec, PFNSSMUSBLIVEVOTE pfnLiveVote,
1008 PFNSSMUSBSAVEPREP pfnSavePrep, PFNSSMUSBSAVEEXEC pfnSaveExec, PFNSSMUSBSAVEDONE pfnSaveDone,
1009 PFNSSMUSBLOADPREP pfnLoadPrep, PFNSSMUSBLOADEXEC pfnLoadExec, PFNSSMUSBLOADDONE pfnLoadDone)
1010{
1011 return pUsbIns->pHlpR3->pfnSSMRegister(pUsbIns, uVersion, cbGuess,
1012 pfnLivePrep, pfnLiveExec, pfnLiveVote,
1013 pfnSavePrep, pfnSaveExec, pfnSaveDone,
1014 pfnLoadPrep, pfnLoadExec, pfnLoadDone);
1015}
1016
1017#endif /* IN_RING3 */
1018
1019
1020
1021/** Pointer to callbacks provided to the VBoxUsbRegister() call. */
1022typedef const struct PDMUSBREGCB *PCPDMUSBREGCB;
1023
1024/**
1025 * Callbacks for VBoxUSBDeviceRegister().
1026 */
1027typedef struct PDMUSBREGCB
1028{
1029 /** Interface version.
1030 * This is set to PDM_USBREG_CB_VERSION. */
1031 uint32_t u32Version;
1032
1033 /**
1034 * Registers a device with the current VM instance.
1035 *
1036 * @returns VBox status code.
1037 * @param pCallbacks Pointer to the callback table.
1038 * @param pReg Pointer to the USB device registration record.
1039 * This data must be permanent and readonly.
1040 */
1041 DECLR3CALLBACKMEMBER(int, pfnRegister,(PCPDMUSBREGCB pCallbacks, PCPDMUSBREG pReg));
1042} PDMUSBREGCB;
1043
1044/** Current version of the PDMUSBREGCB structure. */
1045#define PDM_USBREG_CB_VERSION PDM_VERSION_MAKE(0xeefc, 1, 0)
1046
1047
1048/**
1049 * The VBoxUsbRegister callback function.
1050 *
1051 * PDM will invoke this function after loading a USB device module and letting
1052 * the module decide which devices to register and how to handle conflicts.
1053 *
1054 * @returns VBox status code.
1055 * @param pCallbacks Pointer to the callback table.
1056 * @param u32Version VBox version number.
1057 */
1058typedef DECLCALLBACK(int) FNPDMVBOXUSBREGISTER(PCPDMUSBREGCB pCallbacks, uint32_t u32Version);
1059
1060VMMR3DECL(int) PDMR3UsbCreateEmulatedDevice(PUVM pUVM, const char *pszDeviceName, PCFGMNODE pDeviceNode, PCRTUUID pUuid,
1061 const char *pszCaptureFilename);
1062VMMR3DECL(int) PDMR3UsbCreateProxyDevice(PUVM pUVM, PCRTUUID pUuid, bool fRemote, const char *pszAddress, void *pvBackend,
1063 uint32_t iUsbVersion, uint32_t fMaskedIfs, const char *pszCaptureFilename);
1064VMMR3DECL(int) PDMR3UsbDetachDevice(PUVM pUVM, PCRTUUID pUuid);
1065VMMR3DECL(bool) PDMR3UsbHasHub(PUVM pUVM);
1066VMMR3DECL(int) PDMR3UsbDriverAttach(PUVM pUVM, const char *pszDevice, unsigned iDevIns, unsigned iLun, uint32_t fFlags,
1067 PPPDMIBASE ppBase);
1068VMMR3DECL(int) PDMR3UsbDriverDetach(PUVM pUVM, const char *pszDevice, unsigned iDevIns, unsigned iLun,
1069 const char *pszDriver, unsigned iOccurance, uint32_t fFlags);
1070VMMR3DECL(int) PDMR3UsbQueryLun(PUVM pUVM, const char *pszDevice, unsigned iInstance, unsigned iLun, PPDMIBASE *ppBase);
1071
1072/** @} */
1073
1074RT_C_DECLS_END
1075
1076#endif
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette