* Re: [patch 10/28] posix-cpu-timers: Remove the stub nanosleep functions
From: John Stultz @ 2011-02-01 21:14 UTC (permalink / raw)
To: Thomas Gleixner; +Cc: LKML, Richard Cochran, Ingo Molnar, Peter Zijlstra
In-Reply-To: <20110201134418.422446502@linutronix.de>
On Tue, 2011-02-01 at 13:51 +0000, Thomas Gleixner wrote:
> plain text document attachment
> (posix-cpu-timers-use-default-nsleep-notsup.patch)
> CLOCK_THREAD_CPUTIME_ID implements stub functions for nanosleep and
> nanosleep_restart, which return -EINVAL. That return value is
> wrong. The correct return value is -ENOTSUP.
>
> Remove the stubs and let the new dispatch code return the correct
> error code.
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> Cc: John Stultz <john.stultz@linaro.org>
> Cc: Richard Cochran <richard.cochran@omicron.at>
> ---
Acked-by: John Stultz <johnstul@us.ibm.com>
^ permalink raw reply
* Re: [1.8.0] Change branch --set-uptream to take an argument
From: Jay Soffian @ 2011-02-01 21:14 UTC (permalink / raw)
To: Matthieu Moy; +Cc: Junio C Hamano, git
In-Reply-To: <vpqzkqg5dsq.fsf@bauges.imag.fr>
On Tue, Feb 1, 2011 at 4:01 AM, Matthieu Moy
<Matthieu.Moy@grenoble-inp.fr> wrote:
> Jay Soffian <jaysoffian@gmail.com> writes:
>
>> Currently it is very easy to misinvoke --set-upstream if you assume it
>> takes an argument:
>
> Your proposal sounds interesting, but I'd like to see something more
> global: right now, some commands take a --track option and other take
> a --set-upstream. In short, I'd like to see this --track deprecated
> (since it's not actually about remote-tracking ...).
There are a few things at work here. --track/--no-track are used to
override the branch.autosetupmerge configuration and are supported by
checkout and branch. --set-upstream is only supported by branch, and
is subtly different from --track.
There is also branch.autosetuprebase, for which there is no
command-line option to override.
These options/configs control how branch.<name>.{merge,remote,rebase}
are set. --track/--no-track only take effect when the branch is
created. --set-upstream can be used when the branch is created, or
after the fact.
(Aside, the names of the config params are starting to look
sub-optimal, but it's probably not worth the pain of changing them.)
I suppose a more comprehensive proposal looks like this:
1. Deprecate --track and --no-track (remove from documentation and
usage). I wonder if anyone ever uses them?
2. Deprecate --set-upstream as its usage is confusing.
3. Add -u <name> to both checkout and branch to specify the upstream
branch. It is used with checkout -b in cases where an upstream would
not normally be configured, either because it's not the default
according to branch.autosetupmerge or because the start-point is not a
branch. It is used with branch when creating a branch in a similar
manner to how it's used with checkout when creating a branch, but may
also be used to reset the upstream after the fact like so:
$ git branch -u <upstream> [<branch>]
4. Add --pull-default={rebase,merge} to both checkout and branch used
for setting/unsetting branch.<name>.rebase during initial branch
creation, or after the fact in the case of git-branch. It is an error
to try to set --pull-default if the upstream is not configured, either
automatically or via -u.
>> (Though I'm not sure whether the options parser allows for both
>> --set-upstream and --set-upstream=<arg>)
>
> There are already many instances of this. When <arg> is mandatory, you
> can write either --option <arg> or --option=<arg> (like "git log
> --grep pattern" Vs "git log --grep=pattern"), and when <arg> is
> optional, you can write either --option alone, or --option=<arg> (like
> "git diff --color-words" and "git diff --color-words=.").
Sorry. What I meant was that you'd need the ability to differentiate
between "--set-upstream=foo" and "--set-upstream foo" due to
git-branch's existing semantics. Right now:
$ git branch --set-upstream topic origin/master
Creates topic from origin/master and sets topic's upstream to
origin/master. If --set-upstream suddenly starts taking an argument,
that means something completely different: create a new branch named
origin/master starting at HEAD and set its upstream to "topic".
I think we're better off just deprecating --set-upstream and
introducing the more convenient -u.
j.
^ permalink raw reply
* [PATCH 2/2] compat-wireless: backport of alloc_ordered_workqueue into compat.git
From: Hauke Mehrtens @ 2011-02-01 21:13 UTC (permalink / raw)
To: mcgrof; +Cc: linux-wireless, Hauke Mehrtens
In-Reply-To: <1296594827-30742-1-git-send-email-hauke@hauke-m.de>
The backport of alloc_ordered_workqueue is now in compat.git.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
patches/36-workqueue.patch | 15 ++-------------
1 files changed, 2 insertions(+), 13 deletions(-)
diff --git a/patches/36-workqueue.patch b/patches/36-workqueue.patch
index 06e580d..dfa6d8b 100644
--- a/patches/36-workqueue.patch
+++ b/patches/36-workqueue.patch
@@ -1,20 +1,9 @@
Backport commit 99b88a0ecbdbc6df03527292571b2b442965814a
+The rest is backported in include/linux/compat-2.6.37.h
--- a/net/mac80211/main.c
+++ b/net/mac80211/main.c
-@@ -787,7 +787,11 @@ int ieee80211_register_hw(struct ieee802
- hw->queues = IEEE80211_MAX_QUEUES;
-
- local->workqueue =
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37))
- alloc_ordered_workqueue(wiphy_name(local->hw.wiphy), 0);
-+#else
-+ create_singlethread_workqueue(wiphy_name(local->hw.wiphy));
-+#endif
- if (!local->workqueue) {
- result = -ENOMEM;
- goto fail_workqueue;
-@@ -1002,6 +1006,10 @@ static void __exit ieee80211_exit(void)
+@@ -1002,6 +1002,10 @@ static void __exit ieee80211_exit(void)
rc80211_minstrel_ht_exit();
rc80211_minstrel_exit();
--
1.7.1
^ permalink raw reply related
* [PATCH 1/2] compat-wireless: remove compat for threaded_irq in rt2x00
From: Hauke Mehrtens @ 2011-02-01 21:13 UTC (permalink / raw)
To: mcgrof; +Cc: linux-wireless, Hauke Mehrtens
rt2x00 does not use threaded_irq any more.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
patches/09-threaded-irq.patch | 56 -----------------------------------------
1 files changed, 0 insertions(+), 56 deletions(-)
diff --git a/patches/09-threaded-irq.patch b/patches/09-threaded-irq.patch
index 059e58e..df164e9 100644
--- a/patches/09-threaded-irq.patch
+++ b/patches/09-threaded-irq.patch
@@ -61,59 +61,3 @@ thread in process context as well.
};
/* Data structure for the WLAN parts (802.11 cores) of the b43 chip. */
---- a/drivers/net/wireless/rt2x00/rt2x00.h
-+++ b/drivers/net/wireless/rt2x00/rt2x00.h
-@@ -901,6 +901,10 @@ struct rt2x00_dev {
- * Tasklet for processing tx status reports (rt2800pci).
- */
- struct tasklet_struct txstatus_tasklet;
-+
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,31)
-+ struct compat_threaded_irq irq_compat;
-+#endif
- };
-
- /*
---- a/drivers/net/wireless/rt2x00/rt2x00pci.c
-+++ b/drivers/net/wireless/rt2x00/rt2x00pci.c
-@@ -160,10 +160,18 @@ int rt2x00pci_initialize(struct rt2x00_d
- /*
- * Register interrupt handler.
- */
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,31)
-+ status = compat_request_threaded_irq(&rt2x00dev->irq_compat,
-+ rt2x00dev->irq,
-+ rt2x00dev->ops->lib->irq_handler,
-+ rt2x00dev->ops->lib->irq_handler_thread,
-+ IRQF_SHARED, rt2x00dev->name, rt2x00dev);
-+#else
- status = request_threaded_irq(rt2x00dev->irq,
- rt2x00dev->ops->lib->irq_handler,
- rt2x00dev->ops->lib->irq_handler_thread,
- IRQF_SHARED, rt2x00dev->name, rt2x00dev);
-+#endif
- if (status) {
- ERROR(rt2x00dev, "IRQ %d allocation failed (error %d).\n",
- rt2x00dev->irq, status);
-@@ -187,7 +195,11 @@ void rt2x00pci_uninitialize(struct rt2x0
- /*
- * Free irq line.
- */
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,31)
-+ compat_free_threaded_irq(&rt2x00dev->irq_compat);
-+#else
- free_irq(rt2x00dev->irq, rt2x00dev);
-+#endif
-
- /*
- * Free DMA
-@@ -202,6 +214,9 @@ EXPORT_SYMBOL_GPL(rt2x00pci_uninitialize
- */
- static void rt2x00pci_free_reg(struct rt2x00_dev *rt2x00dev)
- {
-+#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,31)
-+ compat_destroy_threaded_irq(&rt2x00dev->irq_compat);
-+#endif
- kfree(rt2x00dev->rf);
- rt2x00dev->rf = NULL;
-
--
1.7.1
^ permalink raw reply related
* [Cluster-devel] [patch] cman: Minor fixes for checkquorum script
From: Chris Feist @ 2011-02-01 21:13 UTC (permalink / raw)
To: cluster-devel.redhat.com
In-Reply-To: <20110201210800.B834B120198@lists.fedorahosted.org>
cman: Minor fixes for checkquorum script
Remove all references to self-fencing
Removed absolute path the binaries in checkquorum
Added missing uninstall information for SHAREDIRTEX
---
cman/scripts/checkquorum | 14 +++++++-------
make/uninstall.mk | 3 +++
2 files changed, 10 insertions(+), 7 deletions(-)
diff --git a/cman/scripts/checkquorum b/cman/scripts/checkquorum
index 43cbc6d..61934cd 100755
--- a/cman/scripts/checkquorum
+++ b/cman/scripts/checkquorum
@@ -26,14 +26,14 @@ if (($#ARGV != -1) && ($ARGV[0] eq "repair")) {
if (!quorum()) {
if (has_quorum_already_been_formed()) {
- debug("Quorum has already existed, node can be self fenced!\n");
+ debug("Quorum has already existed, node can be rebooted!\n");
if (-e $timerfile) {
$tf = open (FILE, "$timerfile");
$time = <FILE>;
close (FILE);
$timediff = time() - $time;
if ($timediff >= $wait_time) {
- self_fence()
+ reboot()
} else {
$remaining = $wait_time - $timediff;
debug("Time has not exceeded wait time ($remaining seconds remaining).\n");
@@ -45,16 +45,16 @@ if (!quorum()) {
close (FILE);
}
} else {
- debug("This is a new startup no self-fencing will occur.\n");
+ debug("This is a new startup no reboot will occur.\n");
`rm -f $timerfile`;
}
} else {
- debug("Quorum exists, no self-fencing should occur.\n");
+ debug("Quorum exists, no reboot should occur.\n");
`rm -f $timerfile`;
}
sub has_quorum_already_been_formed {
- $oe = `/usr/sbin/corosync-objctl 2>&1 | grep -E "runtime.totem.pg.mrp.srp.operational_entered|Could not initialize objdb library|Cannot connect to quorum service" `;
+ $oe = `corosync-objctl 2>&1 | grep -E "runtime.totem.pg.mrp.srp.operational_entered|Could not initialize objdb library|Cannot connect to quorum service" `;
if ($oe =~ /^Could not/ || $oe =~ /^Cannot/) {
debug("corosync is not running\n");
exit 0;
@@ -79,8 +79,8 @@ sub quorum {
return 0;
}
-sub self_fence {
- debug("Self fencing commencing...\n");
+sub reboot {
+ debug("Reboot commencing...\n");
`rm -f $timerfile`;
if ($hardreboot == 1) {
`echo 1 > /proc/sys/kernel/sysrq`;
diff --git a/make/uninstall.mk b/make/uninstall.mk
index 8440187..01e8d2d 100644
--- a/make/uninstall.mk
+++ b/make/uninstall.mk
@@ -38,6 +38,9 @@ endif
ifdef PKGCONF
${UNINSTALL} ${PKGCONF} ${pkgconfigdir}
endif
+ifdef SHAREDIRTEX
+ ${UNINSTALL} ${SHAREDIRTEX} ${sharedir}
+endif
ifdef SHAREDIRT
${UNINSTALL} ${SHAREDIRT} ${sharedir}
endif
^ permalink raw reply related
* [Cluster-devel] [patch] cman: Added checkquorum script for self fencing
From: Chris Feist @ 2011-02-01 21:13 UTC (permalink / raw)
To: cluster-devel.redhat.com
In-Reply-To: <20110201202222.34399120198@lists.fedorahosted.org>
cman: Added checkquorum script for self fencing
A checkquorum script has been added which when copied to the
/etc/watchdog.d directory will cause the machine to node to reboot
itself if it has lost quorum for ~60 seconds.
Resolves: rhbz#560700
---
cman/Makefile | 2 +-
cman/man/Makefile | 3 +-
cman/man/checkquorum.8 | 29 ++++++++++++++
cman/scripts/Makefile | 10 +++++
cman/scripts/checkquorum | 97 ++++++++++++++++++++++++++++++++++++++++++++++
make/install.mk | 4 ++
6 files changed, 143 insertions(+), 2 deletions(-)
diff --git a/cman/Makefile b/cman/Makefile
index ead0baa..1cf8bc9 100644
--- a/cman/Makefile
+++ b/cman/Makefile
@@ -1,4 +1,4 @@
include ../make/defines.mk
include $(OBJDIR)/make/passthrough.mk
-SUBDIRS=lib cman_tool daemon qdisk notifyd init.d man
+SUBDIRS=lib cman_tool daemon qdisk notifyd init.d man scripts
diff --git a/cman/man/Makefile b/cman/man/Makefile
index df20abb..f7fbebf 100644
--- a/cman/man/Makefile
+++ b/cman/man/Makefile
@@ -5,7 +5,8 @@ MANTARGET= \
qdiskd.8 \
mkqdisk.8 \
cmannotifyd.8 \
- cman_notify.8
+ cman_notify.8 \
+ checkquorum.8
include ../../make/defines.mk
include $(OBJDIR)/make/install.mk
diff --git a/cman/man/checkquorum.8 b/cman/man/checkquorum.8
new file mode 100644
index 0000000..96f61f0
--- /dev/null
+++ b/cman/man/checkquorum.8
@@ -0,0 +1,29 @@
+.TH "checkquorum" "8" "February 2011" "" "Check Quorum Watchdog Script"
+.SH "NAME"
+checkquorum \- Check Quorum Watchdog Script
+.SH "SYNOPSIS"
+\fBcheckquorum
+.SH "DESCRIPTION"
+.PP
+The \fBcheckquorum\fP watchdog script, when copied to the
+.IR /etc/watchdog.d
+directory and after enabling/starting the watchdog daemon causes the node to reboot if quorum is
+lost and not regained within a user configurable amount of time (default: 60 seconds).
+.SH "OPTIONS"
+The checkquorum script includes several options which can be set by editing
+the script with a text editor.
+.TP
+.BR $wait_time
+Amount of time in seconds to wait after quorum is lost before trigger a reboot
+(Default: 60 seconds).
+.TP
+.BR $hardreboot
+Instantly reboot the machine without cleanly shutting down the system.
+Useful when the machine may hang on reboot. Set to 1 to hard reboot the
+system, 0 to do a normal reboot.
+.SH "NOTES"
+\fBcheckquorum\fP should never be called outside of watchdog except for
+debugging purposes.
+
+.SH "SEE ALSO"
+watchdog(8)
diff --git a/cman/scripts/Makefile b/cman/scripts/Makefile
new file mode 100644
index 0000000..b4866c8
--- /dev/null
+++ b/cman/scripts/Makefile
@@ -0,0 +1,10 @@
+SHAREDIRTEX=checkquorum
+
+include ../../make/defines.mk
+include $(OBJDIR)/make/clean.mk
+include $(OBJDIR)/make/install.mk
+include $(OBJDIR)/make/uninstall.mk
+
+all:
+
+clean: generalclean
diff --git a/cman/scripts/checkquorum b/cman/scripts/checkquorum
new file mode 100755
index 0000000..43cbc6d
--- /dev/null
+++ b/cman/scripts/checkquorum
@@ -0,0 +1,97 @@
+#!/usr/bin/perl -w
+# Quorum detection watchdog script
+#
+# This script will return -2 if the node had quorum at one point
+# and then subsequently lost it
+#
+# Copyright 2011 Red Hat, Inc.
+
+# Amount of time in seconds to wait after quorum is lost to fail script
+$wait_time = 60;
+
+# Hard Reboot the system (doesn't cleanly shut down the system)
+$hardreboot = 0;
+
+# Location of temporary file to capture timeouts
+$timerfile = "/var/run/cluster/checkquorum-timer";
+
+# Enable debug messages (0 to disable, 1 to enable)
+$debugval = 0;
+
+# If command is called attempting to 'repair' we automatically fail
+if (($#ARGV != -1) && ($ARGV[0] eq "repair")) {
+ debug ("Failing on repair\n");
+ exit 1;
+}
+
+if (!quorum()) {
+ if (has_quorum_already_been_formed()) {
+ debug("Quorum has already existed, node can be self fenced!\n");
+ if (-e $timerfile) {
+ $tf = open (FILE, "$timerfile");
+ $time = <FILE>;
+ close (FILE);
+ $timediff = time() - $time;
+ if ($timediff >= $wait_time) {
+ self_fence()
+ } else {
+ $remaining = $wait_time - $timediff;
+ debug("Time has not exceeded wait time ($remaining seconds remaining).\n");
+ }
+ } else {
+ debug("Creating timer file...\n");
+ $tf = open (FILE, ">$timerfile");
+ print FILE time();
+ close (FILE);
+ }
+ } else {
+ debug("This is a new startup no self-fencing will occur.\n");
+ `rm -f $timerfile`;
+ }
+} else {
+ debug("Quorum exists, no self-fencing should occur.\n");
+ `rm -f $timerfile`;
+}
+
+sub has_quorum_already_been_formed {
+ $oe = `/usr/sbin/corosync-objctl 2>&1 | grep -E "runtime.totem.pg.mrp.srp.operational_entered|Could not initialize objdb library|Cannot connect to quorum service" `;
+ if ($oe =~ /^Could not/ || $oe =~ /^Cannot/) {
+ debug("corosync is not running\n");
+ exit 0;
+ }
+ $oe =~ s/.*=//;
+ if ($oe > 1) {
+ return 1;
+ } else {
+ return 0;
+ }
+}
+
+sub quorum {
+ $cq = `corosync-quorumtool -s 2>&1 | grep -E "Quorate:|Cannot connect to quorum service"`;
+ if ($cq =~ /Cannot connect to quorum service/) {
+ debug("corosync is not running\n");
+ exit 0;
+ }
+ $cq =~ s/Quorate: *//;
+ chomp ($cq);
+ return 1 if ($cq eq "Yes");
+ return 0;
+}
+
+sub self_fence {
+ debug("Self fencing commencing...\n");
+ `rm -f $timerfile`;
+ if ($hardreboot == 1) {
+ `echo 1 > /proc/sys/kernel/sysrq`;
+ `echo b > /proc/sysrq-trigger`;
+ }
+ exit -2;
+}
+
+sub debug {
+ $out = pop(@_);
+ if ($debugval) {
+ print $out;
+ }
+}
diff --git a/make/install.mk b/make/install.mk
index 3f23bca..fa6ac92 100644
--- a/make/install.mk
+++ b/make/install.mk
@@ -66,6 +66,10 @@ ifdef PKGCONF
install -d ${pkgconfigdir}
install -m644 ${PKGCONF} ${pkgconfigdir}
endif
+ifdef SHAREDIRTEX
+ install -d ${sharedir}
+ install -m755 ${SHAREDIRTEX} ${sharedir}
+endif
ifdef SHAREDIRT
install -d ${sharedir}
install -m644 ${SHAREDIRT} ${sharedir}
^ permalink raw reply related
* [PATCH] drm/radeon/kms: rv6xx+ thermal sensor fixes
From: Alex Deucher @ 2011-02-01 21:12 UTC (permalink / raw)
To: airlied, dri-devel
Some fixes to the thermal sensor code:
- handle negative numbers
- properly handle temp calculation on different asics
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
---
drivers/gpu/drm/radeon/evergreen.c | 21 ++++++++++++---------
drivers/gpu/drm/radeon/r600.c | 8 ++++++--
drivers/gpu/drm/radeon/radeon.h | 8 ++++----
drivers/gpu/drm/radeon/radeon_pm.c | 2 +-
drivers/gpu/drm/radeon/rv770.c | 19 ++++++++++++-------
5 files changed, 35 insertions(+), 23 deletions(-)
diff --git a/drivers/gpu/drm/radeon/evergreen.c b/drivers/gpu/drm/radeon/evergreen.c
index c0ca7dd..0352cd2 100644
--- a/drivers/gpu/drm/radeon/evergreen.c
+++ b/drivers/gpu/drm/radeon/evergreen.c
@@ -97,26 +97,29 @@ u32 evergreen_page_flip(struct radeon_device *rdev, int crtc_id, u64 crtc_base)
}
/* get temperature in millidegrees */
-u32 evergreen_get_temp(struct radeon_device *rdev)
+int evergreen_get_temp(struct radeon_device *rdev)
{
u32 temp = (RREG32(CG_MULT_THERMAL_STATUS) & ASIC_T_MASK) >>
ASIC_T_SHIFT;
u32 actual_temp = 0;
- if ((temp >> 10) & 1)
- actual_temp = 0;
- else if ((temp >> 9) & 1)
+ if (temp & 0x400)
+ actual_temp = -256;
+ else if (temp & 0x200)
actual_temp = 255;
- else
- actual_temp = (temp >> 1) & 0xff;
+ else if (temp & 0x100) {
+ actual_temp = temp & 0x1ff;
+ actual_temp |= ~0x1ff;
+ } else
+ actual_temp = temp & 0xff;
- return actual_temp * 1000;
+ return (actual_temp * 1000) / 2;
}
-u32 sumo_get_temp(struct radeon_device *rdev)
+int sumo_get_temp(struct radeon_device *rdev)
{
u32 temp = RREG32(CG_THERMAL_STATUS) & 0xff;
- u32 actual_temp = (temp >> 1) & 0xff;
+ int actual_temp = temp - 49;
return actual_temp * 1000;
}
diff --git a/drivers/gpu/drm/radeon/r600.c b/drivers/gpu/drm/radeon/r600.c
index f574d9b..c6a580b 100644
--- a/drivers/gpu/drm/radeon/r600.c
+++ b/drivers/gpu/drm/radeon/r600.c
@@ -98,12 +98,16 @@ void r600_irq_disable(struct radeon_device *rdev);
static void r600_pcie_gen2_enable(struct radeon_device *rdev);
/* get temperature in millidegrees */
-u32 rv6xx_get_temp(struct radeon_device *rdev)
+int rv6xx_get_temp(struct radeon_device *rdev)
{
u32 temp = (RREG32(CG_THERMAL_STATUS) & ASIC_T_MASK) >>
ASIC_T_SHIFT;
+ int actual_temp = temp & 0xff;
- return temp * 1000;
+ if (temp & 0x100)
+ actual_temp -= 256;
+
+ return actual_temp * 1000;
}
void r600_pm_get_dynpm_state(struct radeon_device *rdev)
diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h
index 854ddc6..49a6890 100644
--- a/drivers/gpu/drm/radeon/radeon.h
+++ b/drivers/gpu/drm/radeon/radeon.h
@@ -179,10 +179,10 @@ void radeon_combios_get_power_modes(struct radeon_device *rdev);
void radeon_atombios_get_power_modes(struct radeon_device *rdev);
void radeon_atom_set_voltage(struct radeon_device *rdev, u16 level);
void rs690_pm_info(struct radeon_device *rdev);
-extern u32 rv6xx_get_temp(struct radeon_device *rdev);
-extern u32 rv770_get_temp(struct radeon_device *rdev);
-extern u32 evergreen_get_temp(struct radeon_device *rdev);
-extern u32 sumo_get_temp(struct radeon_device *rdev);
+extern int rv6xx_get_temp(struct radeon_device *rdev);
+extern int rv770_get_temp(struct radeon_device *rdev);
+extern int evergreen_get_temp(struct radeon_device *rdev);
+extern int sumo_get_temp(struct radeon_device *rdev);
/*
* Fences.
diff --git a/drivers/gpu/drm/radeon/radeon_pm.c b/drivers/gpu/drm/radeon/radeon_pm.c
index 3b1b2bf..8136200 100644
--- a/drivers/gpu/drm/radeon/radeon_pm.c
+++ b/drivers/gpu/drm/radeon/radeon_pm.c
@@ -430,7 +430,7 @@ static ssize_t radeon_hwmon_show_temp(struct device *dev,
{
struct drm_device *ddev = pci_get_drvdata(to_pci_dev(dev));
struct radeon_device *rdev = ddev->dev_private;
- u32 temp;
+ int temp;
switch (rdev->pm.int_thermal_type) {
case THERMAL_TYPE_RV6XX:
diff --git a/drivers/gpu/drm/radeon/rv770.c b/drivers/gpu/drm/radeon/rv770.c
index 491dc90..2211a32 100644
--- a/drivers/gpu/drm/radeon/rv770.c
+++ b/drivers/gpu/drm/radeon/rv770.c
@@ -78,18 +78,23 @@ u32 rv770_page_flip(struct radeon_device *rdev, int crtc_id, u64 crtc_base)
}
/* get temperature in millidegrees */
-u32 rv770_get_temp(struct radeon_device *rdev)
+int rv770_get_temp(struct radeon_device *rdev)
{
u32 temp = (RREG32(CG_MULT_THERMAL_STATUS) & ASIC_T_MASK) >>
ASIC_T_SHIFT;
- u32 actual_temp = 0;
-
- if ((temp >> 9) & 1)
- actual_temp = 0;
- else
- actual_temp = (temp >> 1) & 0xff;
-
- return actual_temp * 1000;
+ int actual_temp;
+
+ if (temp & 0x400)
+ actual_temp = -256;
+ else if (temp & 0x200)
+ actual_temp = 255;
+ else if (temp & 0x100) {
+ actual_temp = temp & 0x1ff;
+ actual_temp |= ~0x1ff;
+ } else
+ actual_temp = temp & 0xff;
+
+ return (actual_temp * 1000) / 2;
}
void rv770_pm_misc(struct radeon_device *rdev)
--
1.7.1.1
^ permalink raw reply related
* Re: [patch] xfsprogs: repair never return if device removed
From: Christoph Hellwig @ 2011-02-01 21:14 UTC (permalink / raw)
To: Ajeet Yadav; +Cc: xfs
In-Reply-To: <AANLkTikyOfkbtxN3Et5YZRJ2rPpdsVouJkyRW4fDbUG7@mail.gmail.com>
On Mon, Jan 31, 2011 at 11:41:16AM +0900, Ajeet Yadav wrote:
> I did not receive and response / reviews on patch.
The patch looks good, but we'll need a Signed-off-by line to
apply it.
_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs
^ permalink raw reply
* Re: [patch 09/28] thread_info: Remove legacy arg0-3 from restart_block
From: john stultz @ 2011-02-01 21:11 UTC (permalink / raw)
To: Thomas Gleixner; +Cc: LKML, Richard Cochran, Ingo Molnar, Peter Zijlstra
In-Reply-To: <20110201134418.326209775@linutronix.de>
On Tue, 2011-02-01 at 13:51 +0000, Thomas Gleixner wrote:
> plain text document attachment (thread-info-remove-arg0-3.patch)
> posix timers were the last users of the legacy arg0-3 members of
> restart_block. Remove the cruft.
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> Cc: John Stultz <john.stultz@linaro.org>
> Cc: Richard Cochran <richard.cochran@omicron.at>
> ---
Acked-by: John Stultz <johnstul@us.ibm.com>
^ permalink raw reply
* Re: [patch 08/28] posix-timers: Cleanup restart_block usage
From: john stultz @ 2011-02-01 21:11 UTC (permalink / raw)
To: Thomas Gleixner; +Cc: LKML, Richard Cochran, Ingo Molnar, Peter Zijlstra
In-Reply-To: <20110201134418.232288779@linutronix.de>
On Tue, 2011-02-01 at 13:51 +0000, Thomas Gleixner wrote:
> plain text document attachment
> (posix-timers-cleanup-restart-block.patch)
> posix timers still use the legacy arg0-arg3 members of
> restart_block. Use restart_block.nanosleep instead
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> Cc: John Stultz <john.stultz@linaro.org>
> Cc: Richard Cochran <richard.cochran@omicron.at>
[snip]
> long posix_cpu_nsleep_restart(struct restart_block *restart_block)
> {
> - clockid_t which_clock = restart_block->arg0;
> - struct timespec __user *rmtp;
> + clockid_t which_clock = restart_block->nanosleep.index;
> struct timespec t;
> struct itimerspec it;
> int error;
>
> - rmtp = (struct timespec __user *) restart_block->arg1;
> - t.tv_sec = restart_block->arg2;
> - t.tv_nsec = restart_block->arg3;
> + t = ns_to_timespec(restart_block->nanosleep.expires);
>
> - restart_block->fn = do_no_restart_syscall;
> error = do_cpu_nanosleep(which_clock, TIMER_ABSTIME, &t, &it);
>
> if (error == -ERESTART_RESTARTBLOCK) {
> + struct timespec __user *rmtp = restart_block->nanosleep.rmtp;
> /*
> - * Report back to the user the time still remaining.
> - */
> - if (rmtp != NULL && copy_to_user(rmtp, &it.it_value, sizeof *rmtp))
> + * Report back to the user the time still remaining.
> + */
> + if (rmtp && copy_to_user(rmtp, &it.it_value, sizeof *rmtp))
> return -EFAULT;
>
> - restart_block->fn = posix_cpu_nsleep_restart;
> - restart_block->arg0 = which_clock;
> - restart_block->arg1 = (unsigned long) rmtp;
> - restart_block->arg2 = t.tv_sec;
> - restart_block->arg3 = t.tv_nsec;
> + restart_block->nanosleep.expires = timespec_to_ns(&t);
The conversion back and forth from nanoseconds to timespec seems a
little extraneous, but short of reworking all of the do_nanosleep calls
to take a ktime I don't see a clean solution (since hrtimer also uses
the restart_block).
Acked-by: John Stultz <johnstul@us.ibm.com>
thanks
-john
^ permalink raw reply
* Re: [1.8.0] make two-argument fetch update remote branches
From: A Large Angry SCM @ 2011-02-01 21:05 UTC (permalink / raw)
To: Thomas Rast; +Cc: Junio C Hamano, git
In-Reply-To: <201101312244.10047.trast@student.ethz.ch>
On 01/31/2011 04:44 PM, Thomas Rast wrote:
> Proposal:
>
> Running "git fetch origin master" only updates FETCH_HEAD, not
> origin/master, which turns out to be quite confusing for newcomers
> especially after running 'git pull origin master'.
>
> Since the remote branches in some sense reflect the "last known state"
> of the remote, it would make sense to also update them to whatever a
> two-argument fetch got.
>
If this is proposing to break:
get-fetch ${REPO} ${SRC_REF}:${DST_REF}
then I am against this since that form _is_ used and *is* plumbing.
^ permalink raw reply
* Re: pull request: wireless-2.6 2011-02-01
From: David Miller @ 2011-02-01 21:10 UTC (permalink / raw)
To: linville; +Cc: linux-wireless, netdev, linux-kernel
In-Reply-To: <20110201204010.GG2560@tuxdriver.com>
From: "John W. Linville" <linville@tuxdriver.com>
Date: Tue, 1 Feb 2011 15:40:10 -0500
> git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6.git master
Pulled, thanks JOhn.
^ permalink raw reply
* Re: Network performance with small packets
From: Shirley Ma @ 2011-02-01 21:09 UTC (permalink / raw)
To: Sridhar Samudrala
Cc: Steve Dobbelstein, Michael S. Tsirkin, David Miller, kvm,
mashirle, netdev
In-Reply-To: <1296523838.30191.39.camel@sridhar.beaverton.ibm.com>
On Mon, 2011-01-31 at 17:30 -0800, Sridhar Samudrala wrote:
> Yes. It definitely should be 'out'. 'in' should be 0 in the tx path.
>
> I tried a simpler version of this patch without any tunables by
> delaying the signaling until we come out of the for loop.
> It definitely reduced the number of vmexits significantly for small
> message
> guest to host stream test and the throughput went up a little.
>
> diff --git a/drivers/vhost/net.c b/drivers/vhost/net.c
> index 9b3ca10..5f9fae9 100644
> --- a/drivers/vhost/net.c
> +++ b/drivers/vhost/net.c
> @@ -197,7 +197,7 @@ static void handle_tx(struct vhost_net *net)
> if (err != len)
> pr_debug("Truncated TX packet: "
> " len %d != %zd\n", err, len);
> - vhost_add_used_and_signal(&net->dev, vq, head, 0);
> + vhost_add_used(vq, head, 0);
> total_len += len;
> if (unlikely(total_len >= VHOST_NET_WEIGHT)) {
> vhost_poll_queue(&vq->poll);
> @@ -205,6 +205,8 @@ static void handle_tx(struct vhost_net *net)
> }
> }
>
> + if (total_len > 0)
> + vhost_signal(&net->dev, vq);
> mutex_unlock(&vq->mutex);
> }
Reducing the signaling will reduce the CPU utilization by reducing VM
exits.
The small message BW is a problem we have seen faster guest/slow vhost,
even I increased VHOST_NET_WEIGHT times, it didn't help that much for
BW. For large message size, vhost is able to process all packets on
time. I played around with guest/host codes, I only see huge BW
improvement by dropping packets on guest side so far.
Thanks
Shirley
^ permalink raw reply
* Re: Early crash (was: Re: module: show version information for built-in modules in sysfs)
From: Dmitry Torokhov @ 2011-02-01 21:09 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Rusty Russell, linux-kernel@vger.kernel.org, Linux/m68k
In-Reply-To: <AANLkTin4gOnEMruLDM=TkNYsNf5S370WqbcDVJzT7_Z4@mail.gmail.com>
On Tue, Feb 01, 2011 at 12:33:29PM -0800, Geert Uytterhoeven wrote:
> On Mon, Jan 24, 2011 at 11:59, Linux Kernel Mailing List
> <linux-kernel@vger.kernel.org> wrote:
> > Gitweb: http://git.kernel.org/linus/e94965ed5beb23c6fabf7ed31f625e66d7ff28de
>
> > module: show version information for built-in modules in sysfs
> >
> > Currently only drivers that are built as modules have their versions
> > shown in /sys/module/<module_name>/version, but this information might
> > also be useful for built-in drivers as well. This especially important
> > for drivers that do not define any parameters - such drivers, if
> > built-in, are completely invisible from userspace.
> >
> > This patch changes MODULE_VERSION() macro so that in case when we are
> > compiling built-in module, version information is stored in a separate
> > section. Kernel then uses this data to create 'version' sysfs attribute
> > in the same fashion it creates attributes for module parameters.
>
> This commit causes the crash below on m68k (ARAnyM).
> Reverting this commit and its dependency
> 3b90a5b292321b2acac3921f77046ae195aef53f
> ("module: fix linker error for MODULE_VERSION when !MODULE and CONFIG_SYSFS=n")
> makes it boot again.
>
Hi Geert,
Does the follwing help by any chance?
>From d6fd4a6e0fc2d3f0a74962d4a6f663a46d230ecd Mon Sep 17 00:00:00 2001
diff --git a/arch/m68knommu/kernel/vmlinux.lds.S b/arch/m68knommu/kernel/vmlinux.lds.S
index ef33213..47e15eb 100644
--- a/arch/m68knommu/kernel/vmlinux.lds.S
+++ b/arch/m68knommu/kernel/vmlinux.lds.S
@@ -141,6 +141,12 @@ SECTIONS {
*(__param)
__stop___param = .;
+ /* Built-in module versions */
+ . = ALIGN(4) ;
+ __start___modver = .;
+ *(__modver)
+ __stop___modver = .;
+
. = ALIGN(4) ;
_etext = . ;
} > TEXT
Thanks,
Dmitry
^ permalink raw reply related
* Re: Ralink RT2501/RT2573 USB Wireless Adapter crashes kernel 2.6.37
From: Johannes Stezenbach @ 2011-02-01 21:09 UTC (permalink / raw)
To: Eric Fernandez; +Cc: linux-wireless
In-Reply-To: <AANLkTi=VGu6Ysn5WkYjdmVx1+gvzywmqA1-jG5DEL3Eh@mail.gmail.com>
On Tue, Feb 01, 2011 at 08:31:33PM +0000, Eric Fernandez wrote:
> Feb 1 20:22:39 localhost kernel: PGD 154c063 PUD 1fffc067 PMD 80000000c94001e3
> Feb 1 20:22:39 localhost kernel: CPU 1
> Feb 1 20:22:39 localhost kernel: Modules linked in: rt73usb(+)
> rt2500usb rt2x00usb rt2x00lib mac80211 cfg80211 rfkill ipv6 it87
> adt7475 hwmon_vid ext3 jbd nls_cp437 vfat fat joydev usbhid hid
> nvidia(P) uvcvideo videodev v4l1_compat v4l2_compat_ioctl32
...
> Feb 1 20:22:39 localhost kernel: Pid: 7507, comm: modprobe Tainted: P
proprietary modules :-(
> Feb 1 20:22:39 localhost kernel: [<ffffffff812ae58a>] device_add+0x4fa/0x5c0
> Feb 1 20:22:39 localhost kernel: [<ffffffffa00846af>]
> rfkill_register+0x9f/0x270 [rfkill]
> Feb 1 20:22:39 localhost kernel: [<ffffffffa0cdf096>]
> wiphy_register+0x246/0x340 [cfg80211]
> Feb 1 20:22:39 localhost kernel: [<ffffffff81127e2b>] ? __kmalloc+0x19b/0x280
> Feb 1 20:22:39 localhost kernel: [<ffffffffa0d032e7>]
> ieee80211_register_hw+0x167/0x520 [mac80211]
> Feb 1 20:22:39 localhost kernel: [<ffffffffa0d43e40>]
> rt2x00lib_probe_dev+0x2e0/0x4c0 [rt2x00lib]
> Feb 1 20:22:39 localhost kernel: [<ffffffffa01502ad>]
> rt2x00usb_probe+0x14d/0x310 [rt2x00usb]
Can you double check rfkill module is from compat-wireless
and not from you kernel?
Or maybe compat-wireless is currently broken, try an older tarball.
It doesn't look at first glance like a rt2x00 specific issue.
BTW, output from dmesg also contains the actual crash
reason which is not in /var/log/messages due to your syslog config.
HTH,
Johannes
^ permalink raw reply
* Re: Early crash (was: Re: module: show version information for built-in modules in sysfs)
From: Dmitry Torokhov @ 2011-02-01 21:09 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Rusty Russell, linux-kernel@vger.kernel.org, Linux/m68k
In-Reply-To: <AANLkTin4gOnEMruLDM=TkNYsNf5S370WqbcDVJzT7_Z4@mail.gmail.com>
On Tue, Feb 01, 2011 at 12:33:29PM -0800, Geert Uytterhoeven wrote:
> On Mon, Jan 24, 2011 at 11:59, Linux Kernel Mailing List
> <linux-kernel@vger.kernel.org> wrote:
> > Gitweb: http://git.kernel.org/linus/e94965ed5beb23c6fabf7ed31f625e66d7ff28de
>
> > module: show version information for built-in modules in sysfs
> >
> > Currently only drivers that are built as modules have their versions
> > shown in /sys/module/<module_name>/version, but this information might
> > also be useful for built-in drivers as well. This especially important
> > for drivers that do not define any parameters - such drivers, if
> > built-in, are completely invisible from userspace.
> >
> > This patch changes MODULE_VERSION() macro so that in case when we are
> > compiling built-in module, version information is stored in a separate
> > section. Kernel then uses this data to create 'version' sysfs attribute
> > in the same fashion it creates attributes for module parameters.
>
> This commit causes the crash below on m68k (ARAnyM).
> Reverting this commit and its dependency
> 3b90a5b292321b2acac3921f77046ae195aef53f
> ("module: fix linker error for MODULE_VERSION when !MODULE and CONFIG_SYSFS=n")
> makes it boot again.
>
Hi Geert,
Does the follwing help by any chance?
From d6fd4a6e0fc2d3f0a74962d4a6f663a46d230ecd Mon Sep 17 00:00:00 2001
diff --git a/arch/m68knommu/kernel/vmlinux.lds.S b/arch/m68knommu/kernel/vmlinux.lds.S
index ef33213..47e15eb 100644
--- a/arch/m68knommu/kernel/vmlinux.lds.S
+++ b/arch/m68knommu/kernel/vmlinux.lds.S
@@ -141,6 +141,12 @@ SECTIONS {
*(__param)
__stop___param = .;
+ /* Built-in module versions */
+ . = ALIGN(4) ;
+ __start___modver = .;
+ *(__modver)
+ __stop___modver = .;
+
. = ALIGN(4) ;
_etext = . ;
} > TEXT
Thanks,
Dmitry
^ permalink raw reply related
* Re: [patch 07/28] posix-timers: Convert clock_nanosleep_restart to clockid_to_kclock()
From: Thomas Gleixner @ 2011-02-01 21:08 UTC (permalink / raw)
To: John Stultz; +Cc: LKML, Richard Cochran, Ingo Molnar, Peter Zijlstra
In-Reply-To: <alpine.LFD.2.00.1102012145500.31804@localhost6.localdomain6>
On Tue, 1 Feb 2011, Thomas Gleixner wrote:
> On Tue, 1 Feb 2011, John Stultz wrote:
>
> > On Tue, 2011-02-01 at 13:51 +0000, Thomas Gleixner wrote:
> > > plain text document attachment
> > > (posix-timers-convert-nanosleep-restart.patch)
> > > Use the new kclock decoding function in clock_nanosleep_restart. No
> > > need to check kclock here as the restart block always contains a valid
> > > clockid. If not, we are in serious trouble anyway.
> > >
> > > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> > > Cc: John Stultz <john.stultz@linaro.org>
> > > Cc: Richard Cochran <richard.cochran@omicron.at>
> >
> > One nit.
> >
> > > -long
> > > -clock_nanosleep_restart(struct restart_block *restart_block)
> > > +long clock_nanosleep_restart(struct restart_block *restart_block)
> > > {
> > > clockid_t which_clock = restart_block->arg0;
> > > + struct k_clock *kc = clockid_to_kclock(which_clock);
> > >
> > > - return CLOCK_DISPATCH(which_clock, nsleep_restart,
> > > - (restart_block));
> > > + return kc->nsleep_restart(restart_block);
> > > }
> >
> >
> > Should you be checking if kc is null before dereferencing? Or am I being
> > overly paranoid?
>
> See changelog. If we get a corrupted restart_block then checking kc is
> probably the least of our worries.
Ok, I'll add the checks for nsleep_restart and timer_get/set/del, but
I make them a WARN_ON_ONCE() as this is serious data corruption in the
kernel.
Thanks,
tglx
^ permalink raw reply
* Re: [PATCH] e2fsprogs: Fix how we treat user-spcified filesystem size
From: Lukas Czerner @ 2011-02-01 21:08 UTC (permalink / raw)
To: Andreas Dilger; +Cc: Lukas Czerner, linux-ext4, tytso
In-Reply-To: <140BFB14-31E6-4E76-B1DA-5CD8F54FDD5B@dilger.ca>
On Tue, 1 Feb 2011, Andreas Dilger wrote:
> On 2011-02-01, at 12:18, Lukas Czerner wrote:
> > +Optionally, the
> > +.I filesystem-size
> > +parameter may be suffixed by one of the following the units
> > +designators: 'b', 's', 'K', 'M', or 'G',
> > +for blocks count, 512 byte sectors, kilobytes, megabytes, or gigabytes,
> > +respectively.
>
> My reading of parse_num_blocks() shows that 'T' is also accepted as a suffix for terabytes, which I was otherwise going to suggest be added, since this is the normal size for filesystems today. It might be worthwhile _briefly_ mentioning here that these are binary/power-of-two values and not decimal values, instead of the rant further below.
The rant below was ripped of resize2fs man page, but I agree.
>
> Minor technical nit - the proper metric value is lower-case 'k' for kilo, though the upper-case 'M', 'G', and 'T' are correct for mega-, giga-, and terabytes.
You're right, I completely missed 'T', will fix that. Regarding the
minor technical nit, I know that, but I have just ripped that from
resize2fs man page without really paying attention. Anyway thanks for
corrections I'll fix it as well.
>
> > diff --git a/resize/resize2fs.8.in b/resize/resize2fs.8.in
> > --- a/resize/resize2fs.8.in
> > +++ b/resize/resize2fs.8.in
> > @@ -38,13 +38,13 @@ The
> > +designators: 'b', 's', 'K', 'M', or 'G',
> > +for blocks count, 512 byte sectors, kilobytes, megabytes, or gigabytes,
> > +respectively. The
>
> Similarly, this also supports 'T' for terabytes, since it uses the same parse_num_blocks() function.
>
> Cheers, Andreas
>
Thanks!
-Lukas
^ permalink raw reply
* [Bug 27912] Set 'err' in ext4_init_fs() if kset_create_and_add() fails
From: bugzilla-daemon @ 2011-02-01 21:07 UTC (permalink / raw)
To: linux-ext4
In-Reply-To: <bug-27912-13602@https.bugzilla.kernel.org/>
https://bugzilla.kernel.org/show_bug.cgi?id=27912
--- Comment #3 from Eugene A. Shatokhin <dame_eugene@mail.ru> 2011-02-01 21:07:13 ---
I have just built and tested the patched ext4.ko module. Yes, the problem with
/sys/fs/ext4 is now fixed as it was expected.
Obviously, the patch does not fix that problem with 'err' that I reported. So
the patch probably needs to be changed a little.
--
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching the assignee of the bug.
^ permalink raw reply
* Re: [PATCH][SVM] Fix 32bit Windows guest VMs save/restore
From: Wei Huang @ 2011-02-01 21:06 UTC (permalink / raw)
To: Keir Fraser; +Cc: xen-devel@lists.xensource.com
In-Reply-To: <C96D7F89.16623%keir@xen.org>
[-- Attachment #1: Type: text/plain, Size: 680 bytes --]
How does this one look? It should address your concern about duplicating
data in both vcpu and vmcb. I have tested it with both 32bit and 64bit
Windows successfully.
-Wei
=================
Fix 32bit guest VM save/restore issues associated with SYSENTER MSRs on
AMD platforms.
This patch turn-on SYSENTER MSRs interception for 32bit guest VMs on AMD
CPUs. With it, hvm_svm.guest_sysenter_xx fields always contain the
canonical version of SYSENTER MSRs and are used in guest save/restore.
The data fields in VMCB save area are updated as necessary.
Reported-by: James Harper <james.harper@bendigoit.com.au>
Signed-off-by: Wei Huang <wei.huang2@amd.com>
=================
[-- Attachment #2: amd_fix_32bit_save_restore.txt --]
[-- Type: text/plain, Size: 2551 bytes --]
diff -r d972e89797f1 xen/arch/x86/hvm/svm/svm.c
--- a/xen/arch/x86/hvm/svm/svm.c Mon Jan 31 23:57:19 2011 -0600
+++ b/xen/arch/x86/hvm/svm/svm.c Tue Feb 01 15:03:15 2011 -0600
@@ -224,10 +224,11 @@
hvm_update_guest_cr(v, 2);
hvm_update_guest_cr(v, 4);
- v->arch.hvm_svm.guest_sysenter_cs = c->sysenter_cs;
- v->arch.hvm_svm.guest_sysenter_esp = c->sysenter_esp;
- v->arch.hvm_svm.guest_sysenter_eip = c->sysenter_eip;
-
+ /* load sysenter MSRs into VMCB save area and VCPU fields */
+ vmcb->sysenter_cs = v->arch.hvm_svm.guest_sysenter_cs = c->sysenter_cs;
+ vmcb->sysenter_esp = v->arch.hvm_svm.guest_sysenter_esp = c->sysenter_esp;
+ vmcb->sysenter_eip = v->arch.hvm_svm.guest_sysenter_eip = c->sysenter_eip;
+
if ( paging_mode_hap(v->domain) )
{
vmcb_set_np_enable(vmcb, 1);
@@ -433,14 +434,6 @@
if ( lma )
new_efer |= EFER_LME;
vmcb_set_efer(vmcb, new_efer);
-
- /*
- * In legacy mode (EFER.LMA=0) we natively support SYSENTER/SYSEXIT with
- * no need for MSR intercepts. When EFER.LMA=1 we must trap and emulate.
- */
- svm_intercept_msr(v, MSR_IA32_SYSENTER_CS, lma);
- svm_intercept_msr(v, MSR_IA32_SYSENTER_ESP, lma);
- svm_intercept_msr(v, MSR_IA32_SYSENTER_EIP, lma);
}
static void svm_sync_vmcb(struct vcpu *v)
@@ -1142,6 +1135,21 @@
{
struct vcpu *v = current;
struct vmcb_struct *vmcb = v->arch.hvm_svm.vmcb;
+ int sync = 0;
+
+ switch ( msr )
+ {
+ case MSR_IA32_SYSENTER_CS:
+ case MSR_IA32_SYSENTER_ESP:
+ case MSR_IA32_SYSENTER_EIP:
+ sync = 1;
+ break;
+ default:
+ break;
+ }
+
+ if ( sync )
+ svm_sync_vmcb(v);
switch ( msr )
{
@@ -1149,13 +1157,13 @@
goto gpf;
case MSR_IA32_SYSENTER_CS:
- v->arch.hvm_svm.guest_sysenter_cs = msr_content;
+ vmcb->sysenter_cs = v->arch.hvm_svm.guest_sysenter_cs = msr_content;
break;
case MSR_IA32_SYSENTER_ESP:
- v->arch.hvm_svm.guest_sysenter_esp = msr_content;
+ vmcb->sysenter_esp = v->arch.hvm_svm.guest_sysenter_esp = msr_content;
break;
case MSR_IA32_SYSENTER_EIP:
- v->arch.hvm_svm.guest_sysenter_eip = msr_content;
+ vmcb->sysenter_eip = v->arch.hvm_svm.guest_sysenter_eip = msr_content;
break;
case MSR_IA32_DEBUGCTLMSR:
@@ -1213,6 +1221,10 @@
wrmsr_hypervisor_regs(msr, msr_content);
break;
}
+
+ if ( sync )
+ svm_vmload(vmcb);
+
return X86EMUL_OKAY;
gpf:
[-- Attachment #3: Type: text/plain, Size: 138 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel
^ permalink raw reply
* [refpolicy] [PATCH] Add TSS Core Services (TCS) daemon (tcsd) policy
From: Daniel J Walsh @ 2011-02-01 21:05 UTC (permalink / raw)
To: refpolicy
In-Reply-To: <1296501420.26427.46.camel@moss-pluto>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Our version of tcsd policy
Steve I suppose we are going to need this in RHEL6.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/
iEYEARECAAYFAk1IdbcACgkQrlYvE4MpobMaCwCgxr5qZHG1GzFOWwRXvWcex4jW
wdMAn2zU5VwffzfXlkzYM07bOliEw/xS
=4oVi
-----END PGP SIGNATURE-----
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: tcsd.patch
Url: http://oss.tresys.com/pipermail/refpolicy/attachments/20110201/34d32f08/attachment-0001.pl
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tcsd.patch.sig
Type: application/pgp-signature
Size: 72 bytes
Desc: not available
Url : http://oss.tresys.com/pipermail/refpolicy/attachments/20110201/34d32f08/attachment-0001.bin
^ permalink raw reply
* iMX31 MBX registers Porting problem
From: Chris @ 2011-02-01 21:05 UTC (permalink / raw)
To: linux-arm-kernel
In-Reply-To: <AANLkTin4fPo6pKWLCqb+BXNS-hDrWPLEK7QQErbuq15C@mail.gmail.com>
> ?I have gone the extra distance in turning off support in the working kernel
> 2.6.19.2, I have removed nearly everything. I am down to the gpio_port
>
^ permalink raw reply
* [Bug 33172] [r600g] ingame rendering broken (black screen) in ut2003
From: bugzilla-daemon @ 2011-02-01 21:04 UTC (permalink / raw)
To: dri-devel
In-Reply-To: <bug-33172-502@http.bugs.freedesktop.org/>
https://bugs.freedesktop.org/show_bug.cgi?id=33172
Tobias Jakobi <liquid.acid@gmx.net> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
--- Comment #6 from Tobias Jakobi <liquid.acid@gmx.net> 2011-02-01 13:04:35 PST ---
Looks like the problem got fixed by the recent changes to the vertex buffer
upload code. Both ut2003 and ut2004 now work flawlessly.
Thanks Marek!
--
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
^ permalink raw reply
* Re: What's the typical RAID10 setup?
From: Roberto Spadim @ 2011-02-01 21:04 UTC (permalink / raw)
To: Keld Jørn Simonsen; +Cc: David Brown, linux-raid
In-Reply-To: <AANLkTiksG6oJMdJ=z3ZELk=_2FWGRWVVhHUvrBPa2+J1@mail.gmail.com>
the problem for benchmark on linux (mdadm) raid implementation (raid1
vs raid0) is:
raid1 read balance(closest head) is diferent from raid0 read
balance(stripe) algorithm
it´s good but can´t be as fast as raid0 for read intensive (sequential)
the problem of closest head algorithm is it can´t paralelize reads
like raid0 paralelize
2011/2/1 Roberto Spadim <roberto@spadim.com.br>:
>> For sequential reading, this is not true. For random reading and
>> writing I agree with you in theory, but benchmarks show that it is not
>> so, at least for Linux RAID, viz the above URL.
>
> i agree with you, since linux algorith for raid1 is closest head, not
> round robin or time based
>
> there´s some patch on internet (google it: round robin raid1 linux)
> for roundrobin, but none for time based =(
> it´s a point of optimization of today raid1 algorithm
>
> round robin (may be at this mail list)
> http://www.spinics.net/lists/raid/msg30003.html
>
> 2011/2/1 Keld Jørn Simonsen <keld@keldix.com>:
>> On Tue, Feb 01, 2011 at 05:02:46PM +0100, Keld Jørn Simonsen wrote:
>>> On Tue, Feb 01, 2011 at 11:01:33AM +0100, David Brown wrote:
>>> > On 31/01/2011 23:52, Keld Jørn Simonsen wrote:
>>> > >raid1+0 and Linux MD raid10 are similar, but significantly different
>>> > >in a number of ways. Linux MD raid10 can run on only 2 drives.
>>> > >Linux raid10,f2 has almost RAID0 striping performance in sequential read.
>>> > >You can have an odd number of drives in raid10.
>>> > >And you can have as many copies as you like in raid10,
>>> > >
>>> >
>>> > You can make raid10,f2 functionality from raid1+0 by using partitions.
>>> > For example, to get a raid10,f2 equivalent on two drives, partition them
>>> > into equal halves. Then make md0 a raid1 mirror of sda1 and sdb2, and
>>> > md1 a raid1 mirror of sdb1 and sda2. Finally, make md2 a raid0 stripe
>>> > set of md0 and md1.
>>>
>>> I don't think you get the striping performance of raid10,f2 with this
>>> layout. And that is one of the main advantages of raid10,f2 layout.
>>> Have you tried it out?
>>>
>>> As far as I can see the layout of blocks are not alternating between the
>>> disks. You have one raid1 of sda1 and sdb2, there a file is allocated on
>>> blocks sequentially on sda1 and then mirrored on sdb2, where it is also
>>> sequentially allocated. That gives no striping.
>>
>> Well, maybe the RAID0 layer provides the adequate striping.
>> I am noy sure, but it looks like it could hold in theory.
>> One could try it out.
>>
>> One advantage of this scheme could be improved probability
>> When 2 drives fail, eg. in the case of a 4 drive array.
>> The probability of survival of a running system could then
>> be enhaced form 33 % to 66 %.
>>
>> One problem could be the choice of always the lowest block number, which
>> is secured in raid10,f2, but not in a raid0 over raid1 (or raid10,n2) scenario.
>>
>> best regards
>> keld
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>>
>
>
>
> --
> Roberto Spadim
> Spadim Technology / SPAEmpresarial
>
--
Roberto Spadim
Spadim Technology / SPAEmpresarial
--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply
* [PATCH 2/2] compat: add support for kernel 2.6.38
From: Hauke Mehrtens @ 2011-02-01 21:04 UTC (permalink / raw)
To: mcgrof; +Cc: linux-wireless, Hauke Mehrtens
In-Reply-To: <1296594253-21273-1-git-send-email-hauke@hauke-m.de>
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
include/linux/compat-2.6.38.h | 17 -----------------
include/linux/compat-2.6.39.h | 27 +++++++++++++++++++++++++++
include/linux/compat-2.6.h | 1 +
3 files changed, 28 insertions(+), 17 deletions(-)
create mode 100644 include/linux/compat-2.6.39.h
diff --git a/include/linux/compat-2.6.38.h b/include/linux/compat-2.6.38.h
index 0521156..004fe27 100644
--- a/include/linux/compat-2.6.38.h
+++ b/include/linux/compat-2.6.38.h
@@ -8,23 +8,6 @@
#include <linux/kernel.h>
#include <linux/skbuff.h>
-/*
- * This is not part of The 2.6.37 kernel yet but we
- * we use it to optimize the backport code we
- * need to implement. Instead of using ifdefs
- * to check what version of the check we use
- * we just replace all checks on current code
- * with this. I'll submit this upstream too, that
- * way all we'd have to do is to implement this
- * for older kernels, then we would not have to
- * edit the upstrema code for backport efforts.
- */
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
-#define br_port_exists(dev) (dev->priv_flags & IFF_BRIDGE_PORT)
-#else
-#define br_port_exists(dev) (dev->br_port)
-#endif
-
/* rename member in struct mmc_host in include/linux/mmc/host.h */
#define max_segs max_hw_segs
diff --git a/include/linux/compat-2.6.39.h b/include/linux/compat-2.6.39.h
new file mode 100644
index 0000000..c0c98fd
--- /dev/null
+++ b/include/linux/compat-2.6.39.h
@@ -0,0 +1,27 @@
+#ifndef LINUX_26_39_COMPAT_H
+#define LINUX_26_39_COMPAT_H
+
+#include <linux/version.h>
+
+#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,39))
+
+/*
+ * This is not part of The 2.6.37 kernel yet but we
+ * we use it to optimize the backport code we
+ * need to implement. Instead of using ifdefs
+ * to check what version of the check we use
+ * we just replace all checks on current code
+ * with this. I'll submit this upstream too, that
+ * way all we'd have to do is to implement this
+ * for older kernels, then we would not have to
+ * edit the upstrema code for backport efforts.
+ */
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
+#define br_port_exists(dev) (dev->priv_flags & IFF_BRIDGE_PORT)
+#else
+#define br_port_exists(dev) (dev->br_port)
+#endif
+
+#endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,39)) */
+
+#endif /* LINUX_26_39_COMPAT_H */
diff --git a/include/linux/compat-2.6.h b/include/linux/compat-2.6.h
index 2706797..478f833 100644
--- a/include/linux/compat-2.6.h
+++ b/include/linux/compat-2.6.h
@@ -31,5 +31,6 @@
#include <linux/compat-2.6.36.h>
#include <linux/compat-2.6.37.h>
#include <linux/compat-2.6.38.h>
+#include <linux/compat-2.6.39.h>
#endif /* LINUX_26_COMPAT_H */
--
1.7.1
^ permalink raw reply related
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.