Subversion Repositories Kolibri OS

Rev

Rev 3590 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3590 Rev 3799
Line 238... Line 238...
238
    __asm__ __volatile__(
238
    __asm__ __volatile__(
239
    "int $0x40"
239
    "int $0x40"
240
    ::"a"(68), "b"(1));
240
    ::"a"(68), "b"(1));
241
};
241
};
Line -... Line 242...
-
 
242
 
-
 
243
static inline void delay(uint32_t time)
-
 
244
{
-
 
245
    __asm__ __volatile__(
-
 
246
    "int $0x40"
-
 
247
    ::"a"(5), "b"(time)
-
 
248
    :"memory");
-
 
249
};
242
 
250
 
243
static inline
251
static inline
244
void *user_alloc(size_t size)
252
void *user_alloc(size_t size)
245
{
253
{
246
    void  *val;
254
    void  *val;
Line 271... Line 279...
271
    :"=a"(val)
279
    :"=a"(val)
272
    :"a"(68),"b"(26),"c"(base),"d"(offset),"S"(size));
280
    :"a"(68),"b"(26),"c"(base),"d"(offset),"S"(size));
273
    return val;
281
    return val;
274
}
282
}
Line -... Line 283...
-
 
283
 
-
 
284
typedef union
-
 
285
{
-
 
286
    struct
-
 
287
    {
-
 
288
        void   *data;
-
 
289
        size_t  size;
-
 
290
    };
-
 
291
    unsigned long long raw;
-
 
292
}ufile_t;
-
 
293
 
-
 
294
 
-
 
295
static inline ufile_t load_file(char *path)
-
 
296
{
-
 
297
     ufile_t uf;
-
 
298
 
-
 
299
     __asm__ __volatile__ (
-
 
300
     "int $0x40"
-
 
301
     :"=A"(uf.raw)
-
 
302
     :"a" (68), "b"(27),"c"(path));
-
 
303
 
-
 
304
     return uf;
-
 
305
};
-
 
306
    
275
 
307
 
276
static inline int GetScreenSize()
308
static inline int GetScreenSize()
277
{
309
{
Line 278... Line 310...
278
     int retval;
310
     int retval;
Line 337... Line 369...
337
    :"memory");
369
    :"memory");
Line 338... Line 370...
338
 
370
 
339
    return val;
371
    return val;
Line 340... Line -...
340
}
-
 
Line 341... Line 372...
341
 
372
}
Line 342... Line 373...
342
void *load_file(const char *path, size_t *len);
373
 
343
 
374