|CSX_REQUESTWINDOW(9F)||Kernel Functions for Drivers||CSX_REQUESTWINDOW(9F)|
#include <sys/pccard.h> int32_t csx_RequestWindow(client_handle_t ch, window_handle_t *wh, win_req_t *wr);
int32_t csx_ReleaseWindow(window_handle_t wh);
The function csx_ReleaseWindow() releases window resources which were obtained by a call to csx_RequestWindow(). No adapter or socket hardware is modified by this function.
The csx_MapMemPage(9F) and csx_ModifyWindow(9F) functions use the window handle returned by csx_RequestWindow(). This window handle must be freed by calling csx_ReleaseWindow() when the client is done using this window.
The PC Card Attribute or Common Memory offset for this window is set by csx_MapMemPage(9F).
uint32_t Socket; /* socket number */ uint32_t Attributes; /* window flags */ uint32_t Base.base; /* requested window */ /* base address */ acc_handle_t Base.handle; /* returned handle for /* base of window */ uint32_t Size; /* window size requested */ /* or granted */ uint32_t win_params.AccessSpeed; /* window access speed */ uint32_t win_params.IOAddrLines; /* IO address lines decoded */ uint32_t ReqOffset; /* required window offest */
The fields are defined as follows:
The ability to specify the order in which the CPU will reference data is provided by the following Attributes bits, only one of which may be specified:
These values are advisory, not mandatory. For example, data can be ordered without being merged or cached, even though a driver requests unordered, merged and cached together.
All other bits in the Attributes field must be set to 0.
On successful return from csx_RequestWindow(), WIN_OFFSET_SIZE is set in the Attributes field when the client must specify card offsets to csx_MapMemPage(9F) that are a multiple of the window size.
|0||(Reserved - do not use).|
|5-7||(Reserved—do not use.)|
To request a window that supports the WAIT signal, OR-in the WIN_USE_WAIT bit to the AccessSpeed value before calling this function.
It is recommended that clients use the csx_ConvertSpeed(9F) function to generate the appropriate AccessSpeed values rather than manually perturbing the AccessSpeed field.
PC Card 95 Standard, PCMCIA/JEIDA
|July 19, 1996||OmniOS|