Revision 7ed40acf darwin-user/syscall.c

b/darwin-user/syscall.c
367 367
        case 200: /* host_info */
368 368
        {
369 369
            mig_reply_error_t *err = (mig_reply_error_t *)hdr;
370
            struct host_basic_info *data = (void *)(err+1);
370
            struct {
371
                uint32_t unknow1;
372
                uint32_t max_cpus;
373
                uint32_t avail_cpus;
374
                uint32_t memory_size;
375
                uint32_t cpu_type;
376
                uint32_t cpu_subtype;
377
            } *data = (void *)(err+1);
371 378

  
372 379
            DPRINTF("maxcpu = 0x%x\n",   data->max_cpus);
373 380
            DPRINTF("numcpu = 0x%x\n",   data->avail_cpus);
......
1342 1349
    if(name) /* Sometimes sysctl is called with no arg1, ignore */
1343 1350
        ret = get_errno(sysctl(name, namelen, oldp, oldlenp, newp, newlen));
1344 1351

  
1352
#if defined(TARGET_I386) ^ defined(__i386__) || defined(TARGET_PPC) ^ defined(__ppc__)
1345 1353
    if (!is_error(ret) && bswap_syctl(name, namelen, oldp, *oldlenp) != 0) {
1346 1354
        return -ENOTDIR;
1347 1355
    }
1356
#endif
1357

  
1348 1358
    if(name) {
1349 1359
        //bswap_syctl(name, namelen, newp, newlen);
1350 1360
        tswap32s((uint32_t*)oldlenp);

Also available in: Unified diff