Lines Matching refs:fsctx
86 static int raw_fileop_init(void **fsctx,void *devicename);
87 static int raw_fileop_open(void **ref,void *fsctx,char *filename,int mode);
92 static void raw_fileop_uninit(void *fsctx);
112 raw_fsctx_t *fsctx;
117 fsctx = KMALLOC(sizeof(raw_fsctx_t),0);
118 if (!fsctx) {
123 fsctx->raw_dev = console_handle;
124 fsctx->raw_isconsole = TRUE;
127 fsctx->raw_dev = cfe_open(devicename);
128 fsctx->raw_isconsole = FALSE;
131 fsctx->raw_refcnt = 0;
133 if (fsctx->raw_dev >= 0) {
134 *newfsctx = fsctx;
138 KFREE(fsctx);
145 raw_fsctx_t *fsctx;
152 fsctx = (raw_fsctx_t *) fsctx_arg;
160 file->raw_fsctx = fsctx;
186 fsctx->raw_refcnt++;
271 raw_fsctx_t *fsctx = (raw_fsctx_t *) fsctx_arg;
273 if (fsctx->raw_refcnt) {
277 if (fsctx->raw_isconsole == FALSE) {
278 cfe_close(fsctx->raw_dev);
281 KFREE(fsctx);