1. 30 11月, 2012 5 次提交
    • J
      tools: Allow tools to be installed in a user specified location · 55f1f545
      Josh Boyer 提交于
      When building x86_energy_perf_policy or turbostat within the confines of
      a packaging system such as RPM, we need to be able to have it install to
      the buildroot and not the root filesystem of the build machine.  This
      adds a DESTDIR variable that when set will act as a prefix for the
      install location of these tools.
      Signed-off-by: NJosh Boyer <jwboyer@redhat.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      55f1f545
    • M
      tools/power: turbostat: make Makefile a bit more capable · ee0778a3
      Mark Asselstine 提交于
      The turbostat Makefile is pretty simple, its output is placed in the
      same directory as the source, the install rule has no concept of a
      prefix or sysroot, and you can set CC to use a specific compiler but
      not use the more familiar CROSS_COMPILE. By making a few minor changes
      these limitations are removed while leaving the default behavior
      matching what it used to be.
      
      Example build with these changes:
      make CROSS_COMPILE=i686-wrs-linux-gnu- DESTDIR=/tmp install
      
      or from the tools directory
      make CROSS_COMPILE=i686-wrs-linux-gnu- DESTDIR=/tmp turbostat_install
      Signed-off-by: NMark Asselstine <mark.asselstine@windriver.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      ee0778a3
    • C
      tools/power x86_energy_perf_policy: close /proc/stat in for_every_cpu() · 84764a41
      Colin Ian King 提交于
      Instead of returning out of for_every_cpu() we should break out of the loop=
       which will then tidy up correctly by closing the file /proc/stat.
      Signed-off-by: NColin Ian King <colin.king@canonical.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      84764a41
    • L
      tools/power turbostat: v3.0: monitor Watts and Temperature · 889facbe
      Len Brown 提交于
      Show power in Watts and temperature in Celsius
      when hardware support is present.
      
      Intel's Sandy Bridge and Ivy Bridge processor generations support RAPL
      (Run-Time-Average-Power-Limiting).  Per the Intel SDM
      (Intel® 64 and IA-32 Architectures Software Developer Manual)
      RAPL provides hardware energy counters and power control MSRs
      (Model Specific Registers).  RAPL MSRs are designed primarily
      as a method to implement power capping.  However, they are useful
      for monitoring system power whether or not power capping is used.
      
      In addition, Turbostat now shows temperature from DTS
      (Digital Thermal Sensor) and PTM (Package Thermal Monitor) hardware,
      if present.
      
      As before, turbostat reads MSRs, and never writes MSRs.
      
      New columns are present in turbostat output:
      
      The Pkg_W column shows Watts for each package (socket) in the system.
      On multi-socket systems, the system summary on the 1st row shows the sum
      for all sockets together.
      
      The Cor_W column shows Watts due to processors cores.
      Note that Core_W is included in Pkg_W.
      
      The optional GFX_W column shows Watts due to the graphics "un-core".
      Note that GFX_W is included in Pkg_W.
      
      The optional RAM_W column on server processors shows Watts due to DRAM DIMMS.
      As DRAM DIMMs are outside the processor package, RAM_W is not included in Pkg_W.
      
      The optional PKG_% and RAM_% columns on server processors shows the % of time
      in the measurement interval that RAPL power limiting is in effect on the
      package and on DRAM.
      
      Note that the RAPL energy counters have some limitations.
      
      First, hardware updates the counters about once every milli-second.
      This is fine for typical turbostat measurement intervals > 1 sec.
      However, when turbostat is used to measure events that approach
      1ms, the counters are less useful.
      
      Second, the 32-bit energy counters are subject to wrapping.
      For example, a counter incrementing 15 micro-Joule units
      on a 130 Watt TDP server processor could (in theory)
      roll over in about 9 minutes.  Turbostat detects and handles
      up to 1 counter overflow per measurement interval.
      But when the measurement interval exceeds the guaranteed
      counter range, we can't detect if more than 1 overflow occured.
      So in this case turbostat indicates that the results are
      in question by replacing the fractional part of the Watts
      in the output with "**":
      
      Pkg_W  Cor_W GFX_W
        3**    0**   0**
      
      Third, the RAPL counters are energy (Joule) counters -- they sum up
      weighted events in the package to estimate energy consumed.  They are
      not analong power (Watt) meters.  In practice, they tend to under-count
      because they don't cover every possible use of energy in the package.
      The accuracy of the RAPL counters will vary between product generations,
      and between SKU's in the same product generation, and with temperature.
      
      turbostat's -v (verbose) option now displays more power and thermal configuration
      information -- as shown on the turbostat.8 manual page.
      For example, it now displays the Package and DRAM Thermal Design Power (TDP):
      
      cpu0: MSR_PKG_POWER_INFO: 0x2f064001980410 (130 W TDP, RAPL 51 - 200 W, 0.045898 sec.)
      cpu0: MSR_DRAM_POWER_INFO,: 0x28025800780118 (35 W TDP, RAPL 15 - 75 W, 0.039062 sec.)
      cpu8: MSR_PKG_POWER_INFO: 0x2f064001980410 (130 W TDP, RAPL 51 - 200 W, 0.045898 sec.)
      cpu8: MSR_DRAM_POWER_INFO,: 0x28025800780118 (35 W TDP, RAPL 15 - 75 W, 0.039062 sec.)
      Signed-off-by: NLen Brown <len.brown@intel.com>
      889facbe
    • L
      tools/power turbostat: fix output buffering issue · ddac0d68
      Len Brown 提交于
      In periodic mode, turbostat writes to stdout,
      but users were un-able to re-direct stdout, eg.
      
      turbostat > outputfile
      
      would result in an empty outputfile.
      Signed-off-by: NLen Brown <len.brown@intel.com>
      ddac0d68
  2. 27 11月, 2012 1 次提交
    • L
      tools/power turbostat: prevent infinite loop on migration error path · e52966c0
      Len Brown 提交于
      Turbostat assumed if it can't migrate to a CPU, then the CPU
      must have gone off-line and turbostat should re-initialize
      with the new topology.
      
      But if turbostat can not migrate because it is restricted by
      a cpuset, then it will fail to migrate even after re-initialization,
      resulting in an infinite loop.
      
      Spit out a warning when we can't migrate
      and endure only 2 re-initialize cycles in a row
      before giving up and exiting.
      Signed-off-by: NLen Brown <len.brown@intel.com>
      e52966c0
  3. 24 11月, 2012 2 次提交
  4. 01 11月, 2012 2 次提交
  5. 31 10月, 2012 4 次提交
    • L
      Merge tag 'gpio-fixes-v3.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio · bc909421
      Linus Torvalds 提交于
      Pull GPIO fixes from Linus Walleij:
       - Fix a potential bit wrap issue in the Timberdale driver
       - Fix up the buffer allocation size in the 74x164 driver
       - Set the value in direction_output() right in the mvebu driver
       - Return proper error codes for invalid GPIOs
       - Fix an off-mode bug for the OMAP
       - Don't initialize the mask_cach on the mvebu driver
      
      * tag 'gpio-fixes-v3.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio:
        GPIO: mvebu-gpio: Don't initialize the mask_cache
        gpio/omap: fix off-mode bug: clear debounce settings on free/reset
        gpiolib: Don't return -EPROBE_DEFER to sysfs, or for invalid gpios
        gpio: mvebu: correctly set the value in direction_output()
        gpio-74x164: Fix buffer allocation size
        gpio-timberdale: fix a potential wrapping issue
      bc909421
    • L
      Merge tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4 · 8c673cbc
      Linus Torvalds 提交于
      Pull ext4 bugfix from Ted Ts'o:
       "This fixes the root cause of the ext4 data corruption bug which raised
        a ruckus on LWN, Phoronix, and Slashdot.
      
        This bug only showed up when non-standard mount options
        (journal_async_commit and/or journal_checksum) were enabled, and when
        the file system was not cleanly unmounted, but the root cause was the
        inode bitmap modifications was not being properly journaled.
      
        This could potentially lead to minor file system corruptions (pass 5
        complaints with the inode allocation bitmap) after an unclean shutdown
        under the wrong/unlucky workloads, but it turned into major failure if
        the journal_checksum and/or jouaral_async_commit was enabled."
      
      * tag 'ext4_for_linus_stable' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso/ext4:
        ext4: fix unjournaled inode bitmap modification
      8c673cbc
    • L
      Merge branch 'for-linus' of git://git.kernel.dk/linux-block · 4476c0ee
      Linus Torvalds 提交于
      Pull block driver update from Jens Axboe:
       "Distilled down variant, the rest will pass over to 3.8.  I pulled it
        into the for-linus branch I had waiting for a pull request as well, in
        case you are wondering why there are new entries in here too.  This
        also got rid of two reverts and the ones of the mtip32xx patches that
        went in later in the 3.6 cycle, so the series looks a bit cleaner."
      
      * 'for-linus' of git://git.kernel.dk/linux-block:
        loop: Make explicit loop device destruction lazy
        mtip32xx:Added appropriate timeout value for secure erase
        xen/blkback: Change xen_vbd's flush_support and discard_secure to have type unsigned int, rather than bool
        cciss: select CONFIG_CHECK_SIGNATURE
        cciss: remove unneeded memset()
        xen/blkback: use kmem_cache_zalloc instead of kmem_cache_alloc/memset
        pktcdvd: update MAINTAINERS
        floppy: remove dr, reuse drive on do_floppy_init
        floppy: use common function to check if floppies can be registered
        floppy: properly handle failure on add_disk loop
        floppy: do put_disk on current dr if blk_init_queue fails
        floppy: don't call alloc_ordered_workqueue inside the alloc_disk loop
        xen/blkback: Fix compile warning
        block: Add blk_rq_pos(rq) to sort rq when plushing
        drivers/block: remove CONFIG_EXPERIMENTAL
        block: remove CONFIG_EXPERIMENTAL
        vfs: fix: don't increase bio_slab_max if krealloc() fails
        blkcg: stop iteration early if root_rl is the only request list
        blkcg: Fix use-after-free of q->root_blkg and q->root_rl.blkg
      4476c0ee
    • A
      GPIO: mvebu-gpio: Don't initialize the mask_cache · 8fcff5f1
      Andrew Lunn 提交于
      Due to the SMP nature of some of the chips, which have per CPU
      registers, the driver does not use the generic irq_gc_mask_set_bit() &
      irq_gc_mask_clr_bit() functions, which only support a single register.
      The driver has its own implementation of these functions, which can
      pick the correct register depending on the CPU being used. The
      functions do however use the gc->mask_cache value.
      
      The call to irq_setup_generic_chip() was passing
      IRQ_GC_INIT_MASK_CACHE, which caused the gc->mask_cache to be
      initialized to the contents of some random register. This resulted in
      unexpected interrupts been delivered from random GPIO lines.
      Signed-off-by: NAndrew Lunn <andrew@lunn.ch>
      Tested-by: NJamie Lentin <jm@lentin.co.uk>
      Acked-by: NThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Tested-by: NMichael Walle <michael@walle.cc>
      Signed-off-by: NLinus Walleij <linus.walleij@linaro.org>
      8fcff5f1
  6. 30 10月, 2012 13 次提交
  7. 29 10月, 2012 13 次提交