Skip to content
  1. Oct 08, 2009
    • David Miller's avatar
      mm, perf_event: Make vmalloc_user() align base kernel virtual address to SHMLBA · 2dca6999
      David Miller authored
      
      
      When a vmalloc'd area is mmap'd into userspace, some kind of
      co-ordination is necessary for this to work on platforms with cpu
      D-caches which can have aliases.
      
      Otherwise kernel side writes won't be seen properly in userspace
      and vice versa.
      
      If the kernel side mapping and the user side one have the same
      alignment, modulo SHMLBA, this can work as long as VM_SHARED is
      shared of VMA and for all current users this is true.  VM_SHARED
      will force SHMLBA alignment of the user side mmap on platforms with
      D-cache aliasing matters.
      
      The bulk of this patch is just making it so that a specific
      alignment can be passed down into __get_vm_area_node().  All
      existing callers pass in '1' which preserves existing behavior.
      vmalloc_user() gives SHMLBA for the alignment.
      
      As a side effect this should get the video media drivers and other
      vmalloc_user() users into more working shape on such systems.
      
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      Acked-by: default avatarPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Jens Axboe <jens.axboe@oracle.com>
      Cc: Nick Piggin <nickpiggin@yahoo.com.au>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      LKML-Reference: <200909211922.n8LJMYjw029425@imap1.linux-foundation.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      2dca6999
  2. Oct 06, 2009
  3. Oct 05, 2009
  4. Oct 01, 2009
    • Mulyadi Santosa's avatar
      perf tools: Run generate-cmdlist.sh properly · 1ad0560e
      Mulyadi Santosa authored
      
      
      Right now generate-cmdlist.sh is not executable, so we
      should call it as an argument ".".
      
      This fixes cases where due to different umask defaults
      the generate-cmdlist.sh script is not executable in
      a kernel tree checkout.
      
      Signed-off-by: default avatarMulyadi Santosa <mulyadi.santosa@gmail.com>
      Acked-by: default avatarSam Ravnborg <sam@ravnborg.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      LKML-Reference: <f284c33d0909251201w422e9687x8cd3a784e85adf7d@mail.gmail.com>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      1ad0560e
    • Xiao Guangrong's avatar
      perf_event: Clean up perf_event_init_task() · 27f9994c
      Xiao Guangrong authored
      
      
      While at it: we can traverse ctx->group_list to get all
      group leader, it should be safe since we hold ctx->mutex.
      
      Changlog v1->v2:
      
        - remove WARN_ON_ONCE() according to Peter Zijlstra's suggestion
      
      Signed-off-by: default avatarXiao Guangrong <xiaoguangrong@cn.fujitsu.com>
      Acked-by: default avatarPeter Zijlstra <peterz@infradead.org>
      Cc: Paul Mackerras <paulus@samba.org>
      LKML-Reference: <4ABC5AF9.6060808@cn.fujitsu.com>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      27f9994c
    • Xiao Guangrong's avatar
      perf_event: Fix event group handling in __perf_event_sched_*() · 8c9ed8e1
      Xiao Guangrong authored
      Paul Mackerras says:
      
       "Actually, looking at this more closely, it has to be a group
       leader anyway since it's at the top level of ctx->group_list.  In
       fact I see four places where we do:
      
        list_for_each_entry(event, &ctx->group_list, group_entry) {
      	if (event == event->group_leader)
      		...
      
       or the equivalent, three of which appear to have been introduced
       by afedadf2 ("perf_counter: Optimize sched in/out of counters")
       back in May by Peter Z.
      
       As far as I can see the if () is superfluous in each case (a
       singleton event will be a group of 1 and will have its
       group_leader pointing to itself)."
      
       [ See: http://marc.info/?l=linux-kernel&m=125361238901442&w=2 ]
      
      And Peter Zijlstra points out this is a bugfix:
      
       "The intent was to call event_sched_{in,out}() for single event
        groups because that's cheaper than group_sched_{in,out}(),
        however..
      
        - as you noticed, I got the condition wrong, it should have read:
      
            list_empty(&event->sibling_list)
      
        - it failed to call group_can_go_on() which deals with ->exclusive.
      
        - it also doesn't call hw_perf_group_sched_in() which might break
          power."
      
       [ See: http://marc.info/?l=linux-kernel&m=125369523318583&w=2
      
       ]
      
      Changelog v1->v2:
      
       - Fix the title name according to Peter Zijlstra's suggestion
      
       - Remove the comments and WARN_ON_ONCE() as Peter Zijlstra's
         suggestion
      
      Signed-off-by: default avatarXiao Guangrong <xiaoguangrong@cn.fujitsu.com>
      Acked-by: default avatarPeter Zijlstra <peterz@infradead.org>
      Cc: Paul Mackerras <paulus@samba.org>
      LKML-Reference: <4ABC5A55.7000208@cn.fujitsu.com>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      8c9ed8e1
    • Arjan van de Ven's avatar
      perf timechart: Add a power-only mode · 39a90a8e
      Arjan van de Ven authored
      
      
      For doing work on the Linux power management components, I need to
      make long (30+ seconds) traces. Currently, this then results in a
      HUGE svg file, with mostly process data that isn't interesting.
      
      This patch adds a --power-only mode to perf timechart that only
      outputs the CPU power section of the SVG; this significantly
      reduces the size of the SVG file, making even 30+ second traces
      viewable with inkscape.
      
      As a minor tweak for the same effect, the minimum text size is
      decreased; current inkscape cannot zoom in deep enough to show text
      this small, but it reduces inkscape compute time.
      
      Signed-off-by: default avatarArjan van de Ven <arjan@linux.intel.com>
      Cc: peterz@infradead.org
      LKML-Reference: <20090924154013.0675ab71@infradead.org>
      Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
      39a90a8e
  5. Sep 30, 2009
  6. Sep 28, 2009
  7. Sep 27, 2009