07 Oct, 2008

2 commits


27 Aug, 2008

3 commits


26 Aug, 2008

23 commits


25 Aug, 2008

12 commits

  • This patch fixes 3 issues:

    a) it removes the dependency on jiffies, because jiffies are incremented
    by a single CPU, and the tick is not synchronized between CPUs. Therefore
    relying on it to calculate a window to clip whacky TSC values doesn't work
    as it can drift around.

    So instead use [GTOD, GTOD+TICK_NSEC) as the window.

    b) __update_sched_clock() did (roughly speaking):

    delta = sched_clock() - scd->tick_raw;
    clock += delta;

    Which gives exponential growth, instead of linear.

    c) allows the sched_clock_cpu() value to warp the u64 without breaking.

    the results are more reliable sched_clock() deltas:

    before after sched_clock

    cpu_clock: 15750 51312 51488
    cpu_clock: 59719 51052 50947
    cpu_clock: 15879 51249 51061
    cpu_clock: 1 50933 51198
    cpu_clock: 1 50931 51039
    cpu_clock: 1 51093 50981
    cpu_clock: 1 51043 51040
    cpu_clock: 1 50959 50938
    cpu_clock: 1 50981 51011
    cpu_clock: 1 51364 51212
    cpu_clock: 1 51219 51273
    cpu_clock: 1 51389 51048
    cpu_clock: 1 51285 51611
    cpu_clock: 1 50964 51137
    cpu_clock: 1 50973 50968
    cpu_clock: 1 50967 50972
    cpu_clock: 1 58910 58485
    cpu_clock: 1 51082 51025
    cpu_clock: 1 50957 50958
    cpu_clock: 1 50958 50957
    cpu_clock: 1006128 51128 50971
    cpu_clock: 1 51107 51155
    cpu_clock: 1 51371 51081
    cpu_clock: 1 51104 51365
    cpu_clock: 1 51363 51309
    cpu_clock: 1 51107 51160
    cpu_clock: 1 51139 51100
    cpu_clock: 1 51216 51136
    cpu_clock: 1 51207 51215
    cpu_clock: 1 51087 51263
    cpu_clock: 1 51249 51177
    cpu_clock: 1 51519 51412
    cpu_clock: 1 51416 51255
    cpu_clock: 1 51591 51594
    cpu_clock: 1 50966 51374
    cpu_clock: 1 50966 50966
    cpu_clock: 1 51291 50948
    cpu_clock: 1 50973 50867
    cpu_clock: 1 50970 50970
    cpu_clock: 998306 50970 50971
    cpu_clock: 1 50971 50970
    cpu_clock: 1 50970 50970
    cpu_clock: 1 50971 50971
    cpu_clock: 1 50970 50970
    cpu_clock: 1 51351 50970
    cpu_clock: 1 50970 51352
    cpu_clock: 1 50971 50970
    cpu_clock: 1 50970 50970
    cpu_clock: 1 51321 50971
    cpu_clock: 1 50974 51324

    Signed-off-by: Peter Zijlstra
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     
  • Added Intel processor SSE4.2 feature flag.

    No in-tree user at the moment, but makes the tree-merging life easier
    for the crypto tree.

    Signed-off-by: Austin Zhang
    Signed-off-by: Ingo Molnar

    Austin Zhang
     
  • The following part of commit 9ef621d3be56e1188300476a8102ff54f7b6793f
    (KVM: Support mixed endian machines) changed on the size of a struct
    that is exported to userspace:

    include/linux/kvm.h:

    @@ -318,14 +318,14 @@ struct kvm_trace_rec {
    __u32 vcpu_id;
    union {
    struct {
    - __u32 cycle_lo, cycle_hi;
    + __u64 cycle_u64;
    __u32 extra_u32[KVM_TRC_EXTRA_MAX];
    } cycle;
    struct {
    __u32 extra_u32[KVM_TRC_EXTRA_MAX];
    } nocycle;
    } u;
    -};
    +} __attribute__((packed));

    Packing a struct was the correct idea, but it packed the wrong struct.

    Signed-off-by: Adrian Bunk
    Signed-off-by: Avi Kivity

    Adrian Bunk
     
  • The shadow code assigns a pte directly in one place, which is nonatomic on
    i386 can can cause random memory references. Fix by using an atomic setter.

    Signed-off-by: Avi Kivity

    Avi Kivity
     
  • vmlinux.lds expects the fixup code to be on a section named .fixup. The
    .text.fixup section is not mentioned on vmlinux.lds, and is included on
    the resulting vmlinux (just after .text) only because of ld heuristics on
    placing orphan sections.

    However, placing .text.fixup outside .text breaks the definition of
    _etext, making it exclude the .text.fixup contents. That makes .text.fixup
    be ignored by the kernel initialization code that needs to know about
    section locations, such as the code setting page protection bits.

    Signed-off-by: Eduardo Habkost
    Signed-off-by: Avi Kivity

    Eduardo Habkost
     
  • Signed-off-by: Rusty Russell

    Rusty Russell
     
  • Everyone should be using stop_machine() now. The staged API
    transition helped life in linux-next.

    Signed-off-by: Rusty Russell

    Rusty Russell
     
  • This is the last use of (the deprecated) stop_machine_run in the tree.

    Signed-off-by: Rusty Russell
    Acked-by: Jeremy Fitzhardinge

    Rusty Russell
     
  • Both v and vb->num_pages are u32 and unsigned int respectively. If v is less
    than vb->num_pages (and it is, when deflating the balloon), the result is a
    very large 32-bit number. Since we're returning a s64, instead of getting the
    same negative number we desire, we get a very large positive number.

    This handles the case where v < vb->num_pages and ensures we get a small,
    negative, s64 as the result.

    Rusty: please push this for 2.6.27-rc4. It's probably appropriate for the
    stable tree too as it will cause an unexpected OOM when ballooning.

    Signed-off-by: Anthony Liguori
    Signed-off-by: Rusty Russell (simplified)

    Anthony Liguori
     
  • I noticed that my sched_clock() was slow on a number of machine, so I
    started looking at cpufreq.

    The below seems to fix the problem for me.

    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     
  • Ingo Molnar
     
  • Many SoC audio codec drivers have improper freeing of memory in error
    paths.

    * codec is allocated in the platform device probe function, but is not
    freed there in case of error. Instead it is freed in the i2c device
    probe function's error path. However the success or failure of both
    functions is not linked, so this could result in a double free (if
    the platform device is successfully probed, the i2c device probing
    fails and then the platform driver is unregistered.)

    * codec->private_data is allocated in many platform device probe
    functions but not freed in their error paths.

    This patch hopefully solves all these problems.

    Signed-off-by: Jean Delvare
    Signed-off-by: Mark Brown
    Signed-off-by: Takashi Iwai

    Jean Delvare