Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

re: CVS commit: src/sys/compat/linux/common



   
   #if 0
   #ifndef LINUX_UNAME_ARCH
   #define LINUX_UNAME_ARCH machine
   #endif
           strlcpy(linux_machine, LINUX_UNAME_ARCH, sizeof(linux_machine));
           sysctl_createv(clog, 0, &node, NULL,
                          CTLFLAG_PERMANENT,
                          CTLTYPE_STRING, "machine", NULL,
                          NULL, 0, linux_machine, sizeof(linux_machine),
                          LINUX_KERN_VERSION, CTL_EOL);
                       ^^^^^^^^^^^^^^^^^^
   #endif
   
   The second sysctl_createv (which I commented out) always fails with EEXIST
   so I don't see how it could be making a difference. The minimal fix is

right; it's currently broken.  that isn't being questioned.

   to change LINUX_KERN_VERSION on the second create call to something else
   (or allocate it dynamically). I did not see a "machine" sysctl in my linux
   box.

note how there is a compile-time option in the quoted code to set
this?  LINUX_UNAME_ARCH.  what i tried to do was make this sysctlable
but the code i commited is broken (it worked on my test, but i'm not
sure exactly what i did when transferring it somewhere i could run
cvs ci from), and the attempt i made so far to make it use a
dynamically allocated value failed...


i need to set this (to "i686") for a system that expects it (since
that is what "uname -m" says under linux.)


.mrg.



Home | Main Index | Thread Index | Old Index