Find the answer to your Linux question:
Results 1 to 3 of 3
I've been asked to build a new linux kernel that has fair group sharing (yes, it is implemented in newer kernel versions already, but I'm going to be doing it ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Feb 2010
    Posts
    7

    New DEFINEs in include/linux/sched.h not found


    I've been asked to build a new linux kernel that has fair group sharing (yes, it is
    implemented in newer kernel versions already, but I'm going to be doing it using
    the rt scheduler). This is for an Operating Systems class.

    Now then, after I've built everything and recompiled the new kernel, it doesn't
    seem to be able to figure out that I have a new scheduling policy. In particular,
    even though I've placed...

    Code:
    #DEFINE  SCHED_FSG  6
    ...into the include/linux/sched.h header, it doesn't recognize that it's been added.
    (i.e. Trying to compile will give an "Undefined" error.)

    The only way I can make it recognize the newly added policy (so that I can do
    spiffy things like sched_setscheduler()) is to have the include from:

    Code:
    #include "/usr/src/linux-2.6.32.8/include/linux/sched.h"
    rather than the "proper" way of:
    Code:
    #include <linux/sched.h>
    This makes me think that my headers aren't being used and <linux/sched.h> is
    pointing some other version that my system knows of. If that's the case, then
    this is really bad, because it's likely that all of my other modified kernel files
    aren't being used either. Not really sure though.

    Any thoughts on this?

    Thanks,
    -Elleroth

  2. #2
    Linux Guru Rubberman's Avatar
    Join Date
    Apr 2009
    Location
    I can be found either 40 miles west of Chicago, in Chicago, or in a galaxy far, far away.
    Posts
    11,509
    Sorry, but the terms of use for these forums precludes giving help for school work. In any case, you should be able to determine why the correct headers are not being included when you compile. That's pretty much Linux/Unix Programming 101.
    Sometimes, real fast is almost as good as real time.
    Just remember, Semper Gumbi - always be flexible!

  3. #3
    Just Joined!
    Join Date
    Feb 2010
    Posts
    7
    Understood.

    As it turns out (I just figured it out with some friends) there's some magical
    thing that happens when compiling. To get things to be recognized properly, we
    threw a syntax error, tried to compile, it stopped at the error, we fixed it, and then
    recompiled.

    Everything works fine now.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •