openSUSE Commits
Threads by month
- ----- 2024 -----
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
December 2008
- 1 participants
- 817 discussions
Hello community,
here is the log from the commit of package rsyslog for openSUSE:Factory
checked in at Tue Dec 16 17:44:38 CET 2008.
--------
--- rsyslog/rsyslog.changes 2008-09-10 15:11:11.000000000 +0200
+++ /mounts/work_src_done/STABLE/rsyslog/rsyslog.changes 2008-12-15 14:51:15.000000000 +0100
@@ -1,0 +2,8 @@
+Mon Dec 15 14:51:08 CET 2008 - mt(a)suse.de
+
+- Security fix to honor $AllowedSender settings (bnc#457273).
+- Security fix [DoS] from 3.20.2 to emit a discard message every
+ minute only (when DisallowWarning enabled) instead of every time;
+ this prevernts an attacker can fill the disk (bnc#457273).
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
rsyslog-3.18.3-honor-AllowedSender.bnc457273.dif
rsyslog-3.18.3-imudp-discard-msg-DoS.bnc457273.dif
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ rsyslog.spec ++++++
--- /var/tmp/diff_new_pack.R22463/_old 2008-12-16 17:44:05.000000000 +0100
+++ /var/tmp/diff_new_pack.R22463/_new 2008-12-16 17:44:05.000000000 +0100
@@ -23,7 +23,7 @@
%define rsyslog_docdir %{_docdir}/%{name}
%define install_all_modules_in_lib 0
Version: 3.18.3
-Release: 4
+Release: 7
License: GPL v3 or later
Group: System/Daemons
Summary: Rsyslog, the enhanced syslogd for Linux and Unix
@@ -36,6 +36,8 @@
Source4: rsyslog.d.remote.conf.in
Patch0: %{name}-%{upstream_version}.dif
Patch1: %{name}-%{upstream_version}-moddirs.dif
+Patch2: %{name}-%{upstream_version}-honor-AllowedSender.bnc457273.dif
+Patch3: %{name}-%{upstream_version}-imudp-discard-msg-DoS.bnc457273.dif
AutoReqProv: on
PreReq: %insserv_prereq %fillup_prereq /sbin/klogd /etc/init.d/syslog /sbin/checkproc
Provides: syslog
@@ -167,6 +169,8 @@
dos2unix doc/*.html
%patch0 -p0
%patch1 -p0
+%patch2 -p0
+%patch3 -p0
%build
export CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -W -Wall"
@@ -442,6 +446,11 @@
%endif
%changelog
+* Mon Dec 15 2008 mt(a)suse.de
+- Security fix to honor $AllowedSender settings (bnc#457273).
+- Security fix [DoS] from 3.20.2 to emit a discard message every
+ minute only (when DisallowWarning enabled) instead of every time;
+ this prevernts an attacker can fill the disk (bnc#457273).
* Wed Sep 10 2008 schwab(a)suse.de
- Run autoreconf.
* Tue Sep 09 2008 mt(a)suse.de
++++++ rsyslog-3.18.3-honor-AllowedSender.bnc457273.dif ++++++
--- net.c
+++ net.c 2008/12/15 12:01:28
@@ -80,6 +80,31 @@
int ACLAddHostnameOnFail = 0; /* add hostname to acl when DNS resolving has failed */
int ACLDontResolve = 0; /* add hostname to acl instead of resolving it to IP(s) */
+/* sets the correct allow root pointer based on provided type
+ * rgerhards, 2008-12-01
+ */
+static inline rsRetVal
+setAllowRoot(struct AllowedSenders **ppAllowRoot, uchar *pszType)
+{
+ DEFiRet;
+
+ if(!strcmp((char*)pszType, "UDP"))
+ *ppAllowRoot = pAllowedSenders_UDP;
+ else if(!strcmp((char*)pszType, "TCP"))
+ *ppAllowRoot = pAllowedSenders_TCP;
+#ifdef USE_GSSAPI
+ else if(!strcmp((char*)pszType, "GSS"))
+ *ppAllowRoot = pAllowedSenders_GSS;
+#endif
+ else {
+ dbgprintf("program error: invalid allowed sender ID '%s', denying...\n", pszType);
+ ABORT_FINALIZE(RS_RET_CODE_ERR); /* everything is invalid for an invalid type */
+ }
+
+finalize_it:
+ RETiRet;
+}
+
/* Code for handling allowed/disallowed senders
*/
static inline void MaskIP6 (struct in6_addr *addr, uint8_t bits) {
@@ -143,24 +168,28 @@
}
/* function to clear the allowed sender structure in cases where
- * it must be freed (occurs most often when HUPed.
- * TODO: reconsider recursive implementation
- * I think there is also a memory leak, because only the last entry
- * is acutally deleted... -- rgerhards, 2007-12-25
+ * it must be freed (occurs most often when HUPed).
+ * rgerhards, 2008-12-02: revamped this code when we fixed the
+ * interface definition. Now an iterative algorithm is used.
*/
-void clearAllowedSenders (struct AllowedSenders *pAllow)
+static void
+clearAllowedSenders(uchar *pszType)
{
- if (pAllow != NULL) {
- if (pAllow->pNext != NULL)
- clearAllowedSenders (pAllow->pNext);
- else {
- if (F_ISSET(pAllow->allowedSender.flags, ADDR_NAME))
- free (pAllow->allowedSender.addr.HostWildcard);
- else
- free (pAllow->allowedSender.addr.NetAddr);
-
- free (pAllow);
- }
+ struct AllowedSenders *pPrev;
+ struct AllowedSenders *pCurr;
+
+ if(setAllowRoot(&pCurr, pszType) != RS_RET_OK)
+ return; /* if something went wrong, so let's leave */
+
+ while(pCurr != NULL) {
+ pPrev = pCurr;
+ pCurr = pCurr->pNext;
+ /* now delete the entry we are right now processing */
+ if(F_ISSET(pPrev->allowedSender.flags, ADDR_NAME))
+ free(pPrev->allowedSender.addr.HostWildcard);
+ else
+ free(pPrev->allowedSender.addr.NetAddr);
+ free(pPrev);
}
}
@@ -545,12 +574,16 @@
* returns 1, if the sender is allowed, 0 otherwise.
* rgerhards, 2005-09-26
*/
-static int isAllowedSender(struct AllowedSenders *pAllowRoot, struct sockaddr *pFrom, const char *pszFromHost)
+static int isAllowedSender(uchar *pszType, struct sockaddr *pFrom, const char *pszFromHost)
{
struct AllowedSenders *pAllow;
-
+ struct AllowedSenders *pAllowRoot;
+
assert(pFrom != NULL);
+ if(setAllowRoot(&pAllowRoot, pszType) != RS_RET_OK)
+ return 0; /* if something went wrong, we denie access - that's the better choice... */
+
if(pAllowRoot == NULL)
return 1; /* checking disabled, everything is valid! */
--- net.h
+++ net.h 2008/12/15 12:02:00
@@ -92,19 +92,16 @@
/* things to go away after proper modularization */
rsRetVal (*addAllowedSenderLine)(char* pName, uchar** ppRestOfConfLine);
void (*PrintAllowedSenders)(int iListToPrint);
- void (*clearAllowedSenders) ();
+ void (*clearAllowedSenders)(uchar *pszType);
void (*debugListenInfo)(int fd, char *type);
int *(*create_udp_socket)(uchar *hostname, uchar *LogPort, int bIsServer);
void (*closeUDPListenSockets)(int *finet);
- int (*isAllowedSender)(struct AllowedSenders *pAllowRoot, struct sockaddr *pFrom, const char *pszFromHost);
+ int (*isAllowedSender)(uchar *pszType, struct sockaddr *pFrom, const char *pszFromHost);
rsRetVal (*getLocalHostname)(uchar**);
int (*should_use_so_bsdcompat)(void);
/* data memebers - these should go away over time... TODO */
int *pACLAddHostnameOnFail; /* add hostname to acl when DNS resolving has failed */
int *pACLDontResolve; /* add hostname to acl instead of resolving it to IP(s) */
- struct AllowedSenders *pAllowedSenders_UDP;
- struct AllowedSenders *pAllowedSenders_TCP;
- struct AllowedSenders *pAllowedSenders_GSS;
ENDinterface(net)
#define netCURR_IF_VERSION 2 /* increment whenever you change the interface structure! */
--- plugins/imgssapi/imgssapi.c
+++ plugins/imgssapi/imgssapi.c 2008/12/15 12:08:07
@@ -172,10 +172,10 @@
pGSess = (gss_sess_t*) pUsrSess;
if((pGSrv->allowedMethods & ALLOWEDMETHOD_TCP) &&
- net.isAllowedSender(net.pAllowedSenders_TCP, addr, (char*)fromHostFQDN))
+ net.isAllowedSender((uchar*)"TCP", addr, (char*)fromHostFQDN))
allowedMethods |= ALLOWEDMETHOD_TCP;
if((pGSrv->allowedMethods & ALLOWEDMETHOD_GSS) &&
- net.isAllowedSender(net.pAllowedSenders_GSS, addr, (char*)fromHostFQDN))
+ net.isAllowedSender((uchar*)"GSS", addr, (char*)fromHostFQDN))
allowedMethods |= ALLOWEDMETHOD_GSS;
if(allowedMethods && pGSess != NULL)
pGSess->allowedMethods = allowedMethods;
@@ -645,14 +645,8 @@
BEGINafterRun
CODESTARTafterRun
/* do cleanup here */
- if (net.pAllowedSenders_TCP != NULL) {
- net.clearAllowedSenders (net.pAllowedSenders_TCP);
- net.pAllowedSenders_TCP = NULL;
- }
- if (net.pAllowedSenders_GSS != NULL) {
- net.clearAllowedSenders (net.pAllowedSenders_GSS);
- net.pAllowedSenders_GSS = NULL;
- }
+ net.clearAllowedSenders((uchar*)"TCP");
+ net.clearAllowedSenders((uchar*)"GSS");
ENDafterRun
--- plugins/imrelp/imrelp.c
+++ plugins/imrelp/imrelp.c 2008/12/15 11:20:57
@@ -64,7 +64,7 @@
isPermittedHost(struct sockaddr *addr, char *fromHostFQDN, void __attribute__((unused)) *pUsrSrv,
void __attribute__((unused)) *pUsrSess)
{
- return net.isAllowedSender(net.pAllowedSenders_TCP, addr, fromHostFQDN);
+ return net.isAllowedSender((uchar*) "TCP", addr, fromHostFQDN);
}
#endif // #if 0
@@ -135,10 +135,7 @@
CODESTARTafterRun
/* do cleanup here */
#if 0
- if(net.pAllowedSenders_TCP != NULL) {
- net.clearAllowedSenders(net.pAllowedSenders_TCP);
- net.pAllowedSenders_TCP = NULL;
- }
+ net.clearAllowedSenders((uchar*)"TCP");
#endif
ENDafterRun
--- plugins/imtcp/imtcp.c
+++ plugins/imtcp/imtcp.c 2008/12/15 12:08:36
@@ -66,7 +66,7 @@
isPermittedHost(struct sockaddr *addr, char *fromHostFQDN, void __attribute__((unused)) *pUsrSrv,
void __attribute__((unused)) *pUsrSess)
{
- return net.isAllowedSender(net.pAllowedSenders_TCP, addr, fromHostFQDN);
+ return net.isAllowedSender((uchar*)"TCP", addr, fromHostFQDN);
}
@@ -158,10 +158,7 @@
BEGINafterRun
CODESTARTafterRun
/* do cleanup here */
- if(net.pAllowedSenders_TCP != NULL) {
- net.clearAllowedSenders(net.pAllowedSenders_TCP);
- net.pAllowedSenders_TCP = NULL;
- }
+ net.clearAllowedSenders((uchar*)"TCP");
ENDafterRun
--- plugins/imudp/imudp.c
+++ plugins/imudp/imudp.c 2008/12/15 12:09:02
@@ -189,7 +189,7 @@
* configured to do this).
* rgerhards, 2005-09-26
*/
- if(net.isAllowedSender(net.pAllowedSenders_UDP,
+ if(net.isAllowedSender((uchar*)"UDP",
(struct sockaddr *)&frominet, (char*)fromHostFQDN)) {
parseAndSubmitMessage((char*)fromHost, (char*) pRcvBuf, l,
MSG_PARSE_HOSTNAME, NOFLAG, eFLOWCTL_NO_DELAY);
@@ -238,10 +238,7 @@
BEGINafterRun
CODESTARTafterRun
/* do cleanup here */
- if (net.pAllowedSenders_UDP != NULL) {
- net.clearAllowedSenders (net.pAllowedSenders_UDP);
- net.pAllowedSenders_UDP = NULL;
- }
+ net.clearAllowedSenders((uchar*)"UDP");
if(udpLstnSocks != NULL)
net.closeUDPListenSockets(udpLstnSocks);
if(pRcvBuf != NULL)
--- rsyslog.h
+++ rsyslog.h 2008/12/15 12:13:12
@@ -172,6 +172,7 @@
RS_RET_MAIL_NO_TO = -2071, /**< recipient for mail destination is missing */
RS_RET_MAIL_NO_FROM = -2072, /**< sender for mail destination is missing */
RS_RET_INVALID_PRI = -2073, /**< PRI value is invalid */
+ RS_RET_CODE_ERR = -2109, /**< program code (internal) error */
/* RainerScript error messages (range 1000.. 1999) */
RS_RET_SYSVAR_NOT_FOUND = 1001, /**< system variable could not be found (maybe misspelled) */
++++++ rsyslog-3.18.3-imudp-discard-msg-DoS.bnc457273.dif ++++++
--- plugins/imudp/imudp.c
+++ plugins/imudp/imudp.c 2008/12/15 13:43:31
@@ -49,6 +49,10 @@
DEFobjCurrIf(errmsg)
DEFobjCurrIf(net)
+static time_t ttLastDiscard = 0; /* timestamp when a message from a non-permitted sender was last discarded
+ * This shall prevent remote DoS when the "discard on disallowed sender"
+ * message is configured to be logged on occurance of such a case.
+ */
static int *udpLstnSocks = NULL; /* Internet datagram sockets, first element is nbr of elements
* read-only after init(), but beware of restart! */
static uchar *pszBindAddr = NULL; /* IP to bind socket to */
@@ -196,8 +200,15 @@
} else {
dbgprintf("%s is not an allowed sender\n", (char*)fromHostFQDN);
if(option_DisallowWarning) {
- errmsg.LogError(NO_ERRCODE, "UDP message from disallowed sender %s discarded",
+ time_t tt;
+
+ time(&tt);
+ if(tt > ttLastDiscard + 60) {
+ ttLastDiscard = tt;
+ errmsg.LogError(NO_ERRCODE,
+ "UDP message from disallowed sender %s discarded",
(char*)fromHost);
+ }
}
}
}
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package nagios for openSUSE:Factory
checked in at Tue Dec 16 17:43:07 CET 2008.
--------
--- nagios/nagios.changes 2008-12-01 12:20:14.000000000 +0100
+++ /mounts/work_src_done/STABLE/nagios/nagios.changes 2008-12-16 16:02:42.053726000 +0100
@@ -1,0 +2,21 @@
+Tue Dec 9 12:29:09 CET 2008 - cschneemann(a)suse.de
+
+- update to 3.0.6:
+ + Fix for CGI submission of external commands (writing newlines
+ and submitting service comments)
+ + Fix for Apache group membership in RPM spec file
+ + Fix for improper notification propagation command processing
+ + Better out-of-disk-space error handling when writing retention
+ and status files
+ + Disabled adaptive check and eventhandler commands for security
+ reasons
+ + Fix for reading output from system commands (event handlers,
+ etc) that have timed out
+ + Added wildcard host matching in CGIs
+ + Fixes for playing audio alerts in CGIs
+ + Fix for incorrect host status links in status CGI when viewing
+ hostgroup summary
+ + Added support for x509 cert authentication in the CGIs
+- fixes bnc#442275 : nagios: CSRF bug
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
nagios-3.0.5.tar.bz2
New:
----
nagios-3.0.6.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ nagios.spec ++++++
--- /var/tmp/diff_new_pack.f18755/_old 2008-12-16 17:42:42.000000000 +0100
+++ /var/tmp/diff_new_pack.f18755/_new 2008-12-16 17:42:42.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package nagios (Version 3.0.5)
+# spec file for package nagios (Version 3.0.6)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -20,8 +20,8 @@
Name: nagios
Summary: The Nagios Network Monitor
-Version: 3.0.5
-Release: 2
+Version: 3.0.6
+Release: 1
Url: http://www.nagios.org/
License: GPL v2 or later
Group: System/Monitoring
@@ -473,6 +473,24 @@
%_includedir/%realname/*
%changelog
+* Tue Dec 09 2008 cschneemann(a)suse.de
+- update to 3.0.6:
+ + Fix for CGI submission of external commands (writing newlines
+ and submitting service comments)
+ + Fix for Apache group membership in RPM spec file
+ + Fix for improper notification propagation command processing
+ + Better out-of-disk-space error handling when writing retention
+ and status files
+ + Disabled adaptive check and eventhandler commands for security
+ reasons
+ + Fix for reading output from system commands (event handlers,
+ etc) that have timed out
+ + Added wildcard host matching in CGIs
+ + Fixes for playing audio alerts in CGIs
+ + Fix for incorrect host status links in status CGI when viewing
+ hostgroup summary
+ + Added support for x509 cert authentication in the CGIs
+- fixes bnc#442275 : nagios: CSRF bug
* Mon Dec 01 2008 lrupp(a)suse.de
- don't fail if the host has problems to execute newaliases
* Mon Nov 10 2008 lrupp(a)suse.de
++++++ nagios-3.0.5.tar.bz2 -> nagios-3.0.6.tar.bz2 ++++++
++++ 1833 lines of diff (skipped)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package kvm for openSUSE:Factory
checked in at Tue Dec 16 17:42:24 CET 2008.
--------
--- arch/i386/kvm/kvm.changes 2008-12-01 17:09:41.000000000 +0100
+++ /mounts/work_src_done/STABLE/kvm/kvm.changes 2008-12-16 17:28:01.000000000 +0100
@@ -1,0 +2,13 @@
+Tue Dec 16 17:25:22 CET 2008 - agraf(a)suse.de
+
+- upstream backports:
+ - fix NMI injection issues (#458642)
+ - MMU speedups and fixes (#448114)
+ - fix bug in memory slot assignment
+ - makes our kmp work with current svn qemu
+ - fix buffer overflow in cirrus buffer (#448551)
+- AltGr on VNC fix (#450148)
+- add release to sysfs version (#450571)
+- do not emulate CPUs if opening /dev/kvm failed (#458910)
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
kvm-pre81-kernel-0003-KVM-MMU-Fix-aliased-gfns-treated-as-unaliased.patch
kvm-pre81-kernel-0004-KVM-VMX-Set-IGMT-bit-in-EPT-entry.patch
kvm-pre81-kernel-0015-KVM-VMX-Fix-interrupt-loss-during-race-with-NMI.patch
kvm-pre81-kernel-0022-KVM-VMX-Enable-NMI-window-reporting-unconditionall.patch
kvm-pre81-kernel-0023-KVM-MMU-fix-sync-of-ptes-addressed-at-owner-pageta.patch
kvm-pre81-kernel-0024-KVM-VMX-Conditionally-request-interrupt-window-aft.patch
kvm-pre81-kernel-0033-KVM-MMU-avoid-creation-of-unreachable-pages-in-the.patch
kvm-pre81-kernel-0034-KVM-MMU-optimize-set_spte-for-page-sync.patch
kvm-pre81-kernel-0051-KVM-Really-remove-a-slot-when-a-user-ask-us-so.patch
kvm-pre81-kernel-0058-KVM-MMU-use-page-array-in-unsync-walk.patch
kvm-pre81-kernel-0059-KVM-MMU-collapse-remote-TLB-flushes-on-root-sync.patch
kvm-pre81-kernel-0060-KVM-MMU-skip-global-pgtables-on-sync-due-to-cr3-sw.patch
kvm-pre81-kernel-0061-KVM-MMU-prepopulate-the-shadow-on-invlpg.patch
kvm-pre81-kernel-0066-KVM-Advertise-the-bug-in-memory-region-destruction.patch
kvm-pre81-kernel-0067-KVM-Consolidate-userspace-memory-capability-reporti.patch
kvm-pre81-kernel-0068-KVM-MMU-check-for-present-pdptr-shadow-page-in-wal.patch
kvm-pre81-kernel-0070-KVM-VMX-Fix-pending-NMI-vs.-IRQ-race-for-user-spac.patch
kvm-pre81-user-0019-Make-bottom-halves-more-robust.patch
kvm-pre81-user-0021-fix-bdrv_aio_read-API-breakage-in-qcow2-Andrea-Arca.patch
kvm-pre81-user-0033-CVE-2008-4539-fix-a-heap-overflow-in-Cirrus-emulati.patch
kvm-pre81-user-0044-kvm-qemu-increase-size-of-tun-tap-buffer.patch
kvm-pre81-user-0325-kvm-libkvm-export-KVM_CAP_DESTROY_MEMORY_REGION_WO.patch
kvm-preXX-altgr-and-dead-keys-with-VNC.patch
kvm-qemu-no-fallback-if-open-kvm-fails.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ kvm.spec ++++++
--- /var/tmp/diff_new_pack.X16993/_old 2008-12-16 17:42:12.000000000 +0100
+++ /var/tmp/diff_new_pack.X16993/_new 2008-12-16 17:42:12.000000000 +0100
@@ -19,6 +19,7 @@
# icecream 0
%bcond_with vde
+%define kernel_version %(echo `rpm -q --queryformat '%{VERSION}-%{RELEASE}' kernel-source`|sed 's/_/-/g;')
Name: kvm
BuildRequires: SDL-devel alsa alsa-devel gnutls-devel ncurses-devel perl texinfo
@@ -39,7 +40,7 @@
Summary: Kernel-based Virtual Machine
Url: http://kvm.qumranet.com/
Version: 78
-Release: 6
+Release: 7
Source0: %name-%version.tar.bz2
### To update to new version, recompress the kvm-??.tar.gz using:
# rpmbuild -bp kvm.spec --define="_sourcedir `pwd`"
@@ -63,9 +64,10 @@
Patch04: kvm-qemu-default-memsize.patch
Patch05: kvm-explicit-decl.patch
Patch06: kvm-qemu-writeback.patch
+Patch07: kvm-qemu-no-fallback-if-open-kvm-fails.patch
# Sound
-Patch07: kvm-audio.patch
-Patch08: kvm-pulseaudio.patch
+Patch08: kvm-audio.patch
+Patch09: kvm-pulseaudio.patch
# Mac OS X patches
Patch10: kvm-qemu-hpet.patch
Patch11: kvm-qemu-lpc.patch
@@ -83,6 +85,29 @@
Patch90: kvm-bios.patch
# Post-release upstream patches
Patch100: kvm-preXX-init-on-demand.patch
+Patch101: kvm-pre81-kernel-0003-KVM-MMU-Fix-aliased-gfns-treated-as-unaliased.patch
+Patch102: kvm-pre81-kernel-0004-KVM-VMX-Set-IGMT-bit-in-EPT-entry.patch
+Patch103: kvm-pre81-kernel-0015-KVM-VMX-Fix-interrupt-loss-during-race-with-NMI.patch
+Patch104: kvm-pre81-kernel-0022-KVM-VMX-Enable-NMI-window-reporting-unconditionall.patch
+Patch105: kvm-pre81-kernel-0023-KVM-MMU-fix-sync-of-ptes-addressed-at-owner-pageta.patch
+Patch106: kvm-pre81-kernel-0024-KVM-VMX-Conditionally-request-interrupt-window-aft.patch
+Patch107: kvm-pre81-kernel-0033-KVM-MMU-avoid-creation-of-unreachable-pages-in-the.patch
+Patch108: kvm-pre81-kernel-0034-KVM-MMU-optimize-set_spte-for-page-sync.patch
+Patch109: kvm-pre81-kernel-0051-KVM-Really-remove-a-slot-when-a-user-ask-us-so.patch
+Patch110: kvm-pre81-kernel-0058-KVM-MMU-use-page-array-in-unsync-walk.patch
+Patch111: kvm-pre81-kernel-0059-KVM-MMU-collapse-remote-TLB-flushes-on-root-sync.patch
+Patch112: kvm-pre81-kernel-0060-KVM-MMU-skip-global-pgtables-on-sync-due-to-cr3-sw.patch
+Patch113: kvm-pre81-kernel-0061-KVM-MMU-prepopulate-the-shadow-on-invlpg.patch
+Patch114: kvm-pre81-kernel-0066-KVM-Advertise-the-bug-in-memory-region-destruction.patch
+Patch115: kvm-pre81-kernel-0067-KVM-Consolidate-userspace-memory-capability-reporti.patch
+Patch116: kvm-pre81-kernel-0068-KVM-MMU-check-for-present-pdptr-shadow-page-in-wal.patch
+Patch117: kvm-pre81-kernel-0070-KVM-VMX-Fix-pending-NMI-vs.-IRQ-race-for-user-spac.patch
+Patch118: kvm-pre81-user-0019-Make-bottom-halves-more-robust.patch
+Patch119: kvm-pre81-user-0021-fix-bdrv_aio_read-API-breakage-in-qcow2-Andrea-Arca.patch
+Patch120: kvm-pre81-user-0033-CVE-2008-4539-fix-a-heap-overflow-in-Cirrus-emulati.patch
+Patch121: kvm-pre81-user-0044-kvm-qemu-increase-size-of-tun-tap-buffer.patch
+Patch122: kvm-pre81-user-0325-kvm-libkvm-export-KVM_CAP_DESTROY_MEMORY_REGION_WO.patch
+Patch123: kvm-preXX-altgr-and-dead-keys-with-VNC.patch
# for IA64
Source500: ia64-fix-pagesize.pl
Patch500: IA64-kvm-suse.patch
@@ -184,10 +209,11 @@
%patch04 -p1
%patch05 -p1
%patch06 -p1
-# Sound
%patch07 -p1
-%if %suse_version >= 1100
+# Sound
%patch08 -p1
+%if %suse_version >= 1100
+%patch09 -p1
%endif
# Mac OS X guest
%if !%{vanilla}
@@ -209,6 +235,29 @@
%endif
# Post-release patches
%patch100 -p1
+%patch101 -p1
+%patch102 -p1
+%patch103 -p1
+%patch104 -p1
+%patch105 -p1
+%patch106 -p1
+%patch107 -p1
+%patch108 -p1
+%patch109 -p1
+%patch110 -p1
+%patch111 -p1
+%patch112 -p1
+%patch113 -p1
+%patch114 -p1
+%patch115 -p1
+%patch116 -p1
+%patch117 -p1
+%patch118 -p1
+%patch119 -p1
+%patch120 -p1
+%patch121 -p1
+%patch122 -p1
+%patch123 -p0
# IA64 support
%ifarch ia64
%patch500 -p1
@@ -228,6 +277,10 @@
# Patch kvm/user Makefile to accept inital CFLAGS:
sed -i 's/CFLAGS =/CFLAGS +=/' user/Makefile
echo "CFLAGS=%optflags" >> user/config.mak
+# Patch the module version, so we know which kmp was installed:
+for i in `find . -name "*.c"`; do
+ sed -i "s|kvm-%{version}|kvm-%{version}-%{release}|" "$i"
+done
# Main build:
%if !%{vanilla}
make libkvm user qemu %{?bios_targets} %{?jobs:-j%jobs}
@@ -274,11 +327,34 @@
mv .%_mandir/man1/{qemu.1,qemu-kvm.1}
chmod 644 .%_mandir/man1/*
install -D -m 644 %{SOURCE1} %{buildroot}/etc/udev/rules.d/60-kvm.rules
+# there is no --allow-unsupported-modules before openSUSE 11.1
+%if %suse_version <= 1100
+sed -i 's|--allow-unsupported-modules||g' %{buildroot}/etc/udev/rules.d/60-kvm.rules
+%endif
install -D -m 644 %{SOURCE2} %{buildroot}/usr/share/qemu-kvm/kvm-driver-disc-20080318.iso
install -D -m 755 %{SOURCE3} %{buildroot}/usr/share/qemu-kvm/qemu-ifup
%pre
/usr/sbin/groupadd -r kvm 2>/dev/null || :
+# XXX KMPs can not do post scripts for now
+#%if %suse_version <= 1100
+#%define modprobe /sbin/modprobe
+#%else
+#%define modprobe /sbin/modprobe --allow-unsupported-modules
+#%endif
+#%post KMP
+#/sbin/depmod -a || :
+#if [ ! -e /.buildenv ]; then
+# case `uname -r` in
+# %{kernel_version}*)
+# /sbin/rmmod kvm-intel || :
+# /sbin/rmmod kvm-amd || :
+# /sbin/rmmod kvm || :
+# %{modprobe} kvm-amd || :
+# %{modprobe} kvm-intel || :
+# ;;
+# esac
+#fi
%files
%defattr(-,root,root)
@@ -289,6 +365,16 @@
%_mandir/man1/qemu-kvm.1.gz
%changelog
+* Tue Dec 16 2008 agraf(a)suse.de
+- upstream backports:
+ - fix NMI injection issues (#458642)
+ - MMU speedups and fixes (#448114)
+ - fix bug in memory slot assignment
+ - makes our kmp work with current svn qemu
+ - fix buffer overflow in cirrus buffer (#448551)
+- AltGr on VNC fix (#450148)
+- add release to sysfs version (#450571)
+- do not emulate CPUs if opening /dev/kvm failed (#458910)
* Mon Dec 01 2008 agraf(a)suse.de
- update OSX patch to work for kvm-78
* Fri Nov 21 2008 brogers(a)novell.com
++++++ convert-commits-to-patch.sh ++++++
--- /var/tmp/diff_new_pack.X16993/_old 2008-12-16 17:42:12.000000000 +0100
+++ /var/tmp/diff_new_pack.X16993/_new 2008-12-16 17:42:12.000000000 +0100
@@ -1,8 +1,15 @@
-sed '
-s|^--- a/arch/x86/kvm|--- kernel|
-s|^+++ b/arch/x86/kvm|+++ kernel|
+#!/bin/bash
+set -x
+
+sed -i '
+s|^--- a/arch/ia64/kvm|--- kernel/ia64|
+s|^+++ b/arch/ia64/kvm|+++ kernel/ia64|
+s|^--- a/arch/x86/kvm|--- kernel/x86|
+s|^+++ b/arch/x86/kvm|+++ kernel/x86|
s|^--- a/include|--- kernel/include|
s|^+++ b/include|+++ kernel/include|
+s|^--- a/virt/kvm|--- kernel/'$2'|
+s|^+++ b/virt/kvm|+++ kernel/'$2'|
s|^--- a/|--- |
s|^+++ b/|+++ |
' $1
++++++ kvm-pre81-kernel-0003-KVM-MMU-Fix-aliased-gfns-treated-as-unaliased.patch ++++++
>From 59e82188e617a2caf10d2cff3ccdc42211c7042c Mon Sep 17 00:00:00 2001
From: Izik Eidus <ieidus(a)redhat.com>
Date: Fri, 3 Oct 2008 17:40:32 +0300
Subject: [PATCH] KVM: MMU: Fix aliased gfns treated as unaliased
Some areas of kvm x86 mmu are using gfn offset inside a slot without
unaliasing the gfn first. This patch makes sure that the gfn will be
unaliased and add gfn_to_memslot_unaliased() to save the calculating
of the gfn unaliasing in case we have it unaliased already.
Signed-off-by: Izik Eidus <ieidus(a)redhat.com>
Acked-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 14 ++++++++++----
virt/kvm/kvm_main.c | 9 +++++----
2 files changed, 15 insertions(+), 8 deletions(-)
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
index 09e6c56..99e3cc1 100644
--- a/kernel/include/asm-x86/kvm_host.h
+++ b/kernel/include/asm-x86/kvm_host.h
@@ -617,6 +617,8 @@ void kvm_disable_tdp(void);
int load_pdptrs(struct kvm_vcpu *vcpu, unsigned long cr3);
int complete_pio(struct kvm_vcpu *vcpu);
+struct kvm_memory_slot *gfn_to_memslot_unaliased(struct kvm *kvm, gfn_t gfn);
+
static inline struct kvm_mmu_page *page_header(hpa_t shadow_page)
{
struct page *page = pfn_to_page(shadow_page >> PAGE_SHIFT);
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index a191e5b..0813a08 100644
--- a/kernel/x86/mmu.c
+++ a/kernel/x86/mmu.c
@@ -386,7 +386,9 @@ static void account_shadowed(struct kvm *kvm, gfn_t gfn)
{
int *write_count;
- write_count = slot_largepage_idx(gfn, gfn_to_memslot(kvm, gfn));
+ gfn = unalias_gfn(kvm, gfn);
+ write_count = slot_largepage_idx(gfn,
+ gfn_to_memslot_unaliased(kvm, gfn));
*write_count += 1;
}
@@ -394,16 +396,20 @@ static void unaccount_shadowed(struct kvm *kvm, gfn_t gfn)
{
int *write_count;
- write_count = slot_largepage_idx(gfn, gfn_to_memslot(kvm, gfn));
+ gfn = unalias_gfn(kvm, gfn);
+ write_count = slot_largepage_idx(gfn,
+ gfn_to_memslot_unaliased(kvm, gfn));
*write_count -= 1;
WARN_ON(*write_count < 0);
}
static int has_wrprotected_page(struct kvm *kvm, gfn_t gfn)
{
- struct kvm_memory_slot *slot = gfn_to_memslot(kvm, gfn);
+ struct kvm_memory_slot *slot;
int *largepage_idx;
+ gfn = unalias_gfn(kvm, gfn);
+ slot = gfn_to_memslot_unaliased(kvm, gfn);
if (slot) {
largepage_idx = slot_largepage_idx(gfn, slot);
return *largepage_idx;
@@ -2973,8 +2979,8 @@ static void audit_write_protection(struct kvm_vcpu *vcpu)
if (sp->role.metaphysical)
continue;
- slot = gfn_to_memslot(vcpu->kvm, sp->gfn);
gfn = unalias_gfn(vcpu->kvm, sp->gfn);
+ slot = gfn_to_memslot_unaliased(vcpu->kvm, sp->gfn);
rmapp = &slot->rmap[gfn - slot->base_gfn];
if (*rmapp)
printk(KERN_ERR "%s: (%s) shadow page has writable"
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index 1838052..a65baa9 100644
--- a/kernel/x86/kvm_main.c
+++ a/kernel/x86/kvm_main.c
@@ -923,7 +923,7 @@ int kvm_is_error_hva(unsigned long addr)
}
EXPORT_SYMBOL_GPL(kvm_is_error_hva);
-static struct kvm_memory_slot *__gfn_to_memslot(struct kvm *kvm, gfn_t gfn)
+struct kvm_memory_slot *gfn_to_memslot_unaliased(struct kvm *kvm, gfn_t gfn)
{
int i;
@@ -936,11 +936,12 @@ static struct kvm_memory_slot *__gfn_to_memslot(struct kvm *kvm, gfn_t gfn)
}
return NULL;
}
+EXPORT_SYMBOL_GPL(gfn_to_memslot_unaliased);
struct kvm_memory_slot *gfn_to_memslot(struct kvm *kvm, gfn_t gfn)
{
gfn = unalias_gfn(kvm, gfn);
- return __gfn_to_memslot(kvm, gfn);
+ return gfn_to_memslot_unaliased(kvm, gfn);
}
int kvm_is_visible_gfn(struct kvm *kvm, gfn_t gfn)
@@ -964,7 +965,7 @@ unsigned long gfn_to_hva(struct kvm *kvm, gfn_t gfn)
struct kvm_memory_slot *slot;
gfn = unalias_gfn(kvm, gfn);
- slot = __gfn_to_memslot(kvm, gfn);
+ slot = gfn_to_memslot_unaliased(kvm, gfn);
if (!slot)
return bad_hva();
return (slot->userspace_addr + (gfn - slot->base_gfn) * PAGE_SIZE);
@@ -1215,7 +1216,7 @@ void mark_page_dirty(struct kvm *kvm, gfn_t gfn)
struct kvm_memory_slot *memslot;
gfn = unalias_gfn(kvm, gfn);
- memslot = __gfn_to_memslot(kvm, gfn);
+ memslot = gfn_to_memslot_unaliased(kvm, gfn);
if (memslot && memslot->dirty_bitmap) {
unsigned long rel_gfn = gfn - memslot->base_gfn;
--
1.5.6
++++++ kvm-pre81-kernel-0004-KVM-VMX-Set-IGMT-bit-in-EPT-entry.patch ++++++
>From f80d172a9cbeb80923481e0b2584bc10f76879ee Mon Sep 17 00:00:00 2001
From: Sheng Yang <sheng(a)linux.intel.com>
Date: Thu, 6 Nov 2008 14:55:45 +0800
Subject: [PATCH] KVM: VMX: Set IGMT bit in EPT entry
There is a potential issue that, when guest using pagetable without vmexit when
EPT enabled, guest would use PAT/PCD/PWT bits to index PAT msr for it's memory,
which would be inconsistent with host side and would cause host MCE due to
inconsistent cache attribute.
The patch set IGMT bit in EPT entry to ignore guest PAT and use WB as default
memory type to protect host (notice that all memory mapped by KVM should be WB).
Signed-off-by: Sheng Yang <sheng(a)linux.intel.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/vmx.c | 3 ++-
arch/x86/kvm/vmx.h | 1 +
2 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index ece9cb7..8043352 100644
--- a/kernel/x86/vmx.c
+++ a/kernel/x86/vmx.c
@@ -3692,7 +3692,8 @@ static int __init vmx_init(void)
if (vm_need_ept()) {
bypass_guest_pf = 0;
kvm_mmu_set_base_ptes(VMX_EPT_READABLE_MASK |
- VMX_EPT_WRITABLE_MASK);
+ VMX_EPT_WRITABLE_MASK |
+ VMX_EPT_IGMT_BIT);
kvm_mmu_set_mask_ptes(0ull, 0ull, 0ull, 0ull,
VMX_EPT_EXECUTABLE_MASK,
VMX_EPT_DEFAULT_MT << VMX_EPT_MT_EPTE_SHIFT);
diff --git a/arch/x86/kvm/vmx.h b/arch/x86/kvm/vmx.h
index e2341d8..3db236c 100644
--- a/kernel/x86/vmx.h
+++ a/kernel/x86/vmx.h
@@ -360,6 +360,7 @@ enum vmcs_field {
#define VMX_EPT_READABLE_MASK 0x1ull
#define VMX_EPT_WRITABLE_MASK 0x2ull
#define VMX_EPT_EXECUTABLE_MASK 0x4ull
+#define VMX_EPT_IGMT_BIT (1ull << 6)
#define VMX_EPT_IDENTITY_PAGETABLE_ADDR 0xfffbc000ul
--
1.5.6
++++++ kvm-pre81-kernel-0015-KVM-VMX-Fix-interrupt-loss-during-race-with-NMI.patch ++++++
>From b55a50582030cf294a675492d7ab2e235b965cc8 Mon Sep 17 00:00:00 2001
From: Avi Kivity <avi(a)redhat.com>
Date: Thu, 20 Nov 2008 11:47:18 +0200
Subject: [PATCH] KVM: VMX: Fix interrupt loss during race with NMI
If an interrupt cannot be injected for some reason (say, page fault
when fetching the IDT descriptor), the interrupt is marked for
reinjection. However, if an NMI is queued at this time, the NMI
will be injected instead and the NMI will be lost.
Fix by deferring the NMI injection until the interrupt has been
injected successfully.
Analyzed by Jan Kiszka.
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/vmx.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index ebf5406..93f9010 100644
--- a/kernel/x86/vmx.c
+++ a/kernel/x86/vmx.c
@@ -3268,7 +3268,10 @@ static void vmx_intr_assist(struct kvm_vcpu *vcpu)
vmx_update_window_states(vcpu);
if (vcpu->arch.nmi_pending && !vcpu->arch.nmi_injected) {
- if (vcpu->arch.nmi_window_open) {
+ if (vcpu->arch.interrupt.pending) {
+ if (!vcpu->arch.nmi_window_open)
+ enable_nmi_window(vcpu);
+ } else if (vcpu->arch.nmi_window_open) {
vcpu->arch.nmi_pending = false;
vcpu->arch.nmi_injected = true;
} else {
--
1.5.6
++++++ kvm-pre81-kernel-0022-KVM-VMX-Enable-NMI-window-reporting-unconditionall.patch ++++++
>From d3a2c20c9b850d92dae383fd6a64840de2687cd6 Mon Sep 17 00:00:00 2001
From: Avi Kivity <avi(a)redhat.com>
Date: Sat, 22 Nov 2008 18:42:40 +0200
Subject: [PATCH] KVM: VMX: Enable NMI window reporting unconditionally if deferring nmi injection
If we are deferring an NMI injection due to an interrupt being reinjected,
enable the NMI window unconditionally, so we don't have excess latency for
the NMI injection. Previously we only enabled the NMI window if it was
previously closed, which is a rare and unintersting situation.
Noted by Jan Kiszka.
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/vmx.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index 98c1e47..f5958a7 100644
--- a/kernel/x86/vmx.c
+++ a/kernel/x86/vmx.c
@@ -3278,8 +3278,7 @@ static void vmx_intr_assist(struct kvm_vcpu *vcpu)
if (vcpu->arch.nmi_pending && !vcpu->arch.nmi_injected) {
if (vcpu->arch.interrupt.pending) {
- if (!vcpu->arch.nmi_window_open)
- enable_nmi_window(vcpu);
+ enable_nmi_window(vcpu);
} else if (vcpu->arch.nmi_window_open) {
vcpu->arch.nmi_pending = false;
vcpu->arch.nmi_injected = true;
--
1.5.6
++++++ kvm-pre81-kernel-0023-KVM-MMU-fix-sync-of-ptes-addressed-at-owner-pageta.patch ++++++
>From d7821121b97156765de75cbcfc00b5c183a4c1e1 Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Fri, 21 Nov 2008 19:13:58 +0100
Subject: [PATCH] KVM: MMU: fix sync of ptes addressed at owner pagetable
During page sync, if a pagetable contains a self referencing pte (that
points to the pagetable), the corresponding spte may be marked as
writable even though all mappings are supposed to be write protected.
Fix by clearing page unsync before syncing individual sptes.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 7d77730..fa3486d 100644
--- a/kernel/x86/mmu.c
+++ a/kernel/x86/mmu.c
@@ -1046,13 +1046,13 @@ static int kvm_sync_page(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp)
}
rmap_write_protect(vcpu->kvm, sp->gfn);
+ kvm_unlink_unsync_page(vcpu->kvm, sp);
if (vcpu->arch.mmu.sync_page(vcpu, sp)) {
kvm_mmu_zap_page(vcpu->kvm, sp);
return 1;
}
kvm_mmu_flush_tlb(vcpu);
- kvm_unlink_unsync_page(vcpu->kvm, sp);
return 0;
}
--
1.5.6
++++++ kvm-pre81-kernel-0024-KVM-VMX-Conditionally-request-interrupt-window-aft.patch ++++++
>From 0f7d3ee64e9324b265d5b988c2e81ac1784fc59d Mon Sep 17 00:00:00 2001
From: Avi Kivity <avi(a)redhat.com>
Date: Sun, 23 Nov 2008 18:08:57 +0200
Subject: [PATCH] KVM: VMX: Conditionally request interrupt window after injecting irq
If we're injecting an interrupt, and another one is pending, request
an interrupt window notification so we don't have excess latency on the
second interrupt.
This shouldn't happen in practice since an EOI will be issued, giving a second
chance to request an interrupt window, but...
Signed-off-by: Avi Kivity <avi(a)qumranet.com>
---
arch/x86/kvm/vmx.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index f5958a7..7ea4855 100644
--- a/kernel/x86/vmx.c
+++ a/kernel/x86/vmx.c
@@ -3304,6 +3304,8 @@ static void vmx_intr_assist(struct kvm_vcpu *vcpu)
if (vcpu->arch.interrupt.pending) {
vmx_inject_irq(vcpu, vcpu->arch.interrupt.nr);
kvm_timer_intr_post(vcpu, vcpu->arch.interrupt.nr);
+ if (kvm_cpu_has_interrupt(vcpu))
+ enable_irq_window(vcpu);
}
}
--
1.5.6
++++++ kvm-pre81-kernel-0033-KVM-MMU-avoid-creation-of-unreachable-pages-in-the.patch ++++++
>From 4faf9dd6b58f9f317326c1648e9bc08b6e6f109e Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Tue, 25 Nov 2008 15:33:10 +0100
Subject: [PATCH] KVM: MMU: avoid creation of unreachable pages in the shadow
It is possible for a shadow page to have a parent link
pointing to a freed page. When zapping a high level table,
kvm_mmu_page_unlink_children fails to remove the parent_pte link.
For that to happen, the child must be unreachable via the shadow
tree, which can happen in shadow_walk_entry if the guest pte was
modified in between walk() and fetch(). Remove the parent pte
reference in such case.
Possible cause for oops in bug #2217430.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/paging_tmpl.h | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h
index 613ec9a..84eee43 100644
--- a/kernel/x86/paging_tmpl.h
+++ a/kernel/x86/paging_tmpl.h
@@ -331,6 +331,7 @@ static int FNAME(shadow_walk_entry)(struct kvm_shadow_walk *_sw,
r = kvm_read_guest_atomic(vcpu->kvm, gw->pte_gpa[level - 2],
&curr_pte, sizeof(curr_pte));
if (r || curr_pte != gw->ptes[level - 2]) {
+ kvm_mmu_put_page(shadow_page, sptep);
kvm_release_pfn_clean(sw->pfn);
sw->sptep = NULL;
return 1;
--
1.5.6
++++++ kvm-pre81-kernel-0034-KVM-MMU-optimize-set_spte-for-page-sync.patch ++++++
>From 7cf15b18d2660bdba17e779979d202b5642cda50 Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Tue, 25 Nov 2008 15:58:07 +0100
Subject: [PATCH] KVM: MMU: optimize set_spte for page sync
The write protect verification in set_spte is unnecessary for page sync.
Its guaranteed that, if the unsync spte was writable, the target page
does not have a write protected shadow (if it had, the spte would have
been write protected under mmu_lock by rmap_write_protect before).
Same reasoning applies to mark_page_dirty: the gfn has been marked as
dirty via the pagefault path.
The cost of hash table and memslot lookups are quite significant if the
workload is pagetable write intensive resulting in increased mmu_lock
contention.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 9 +++++++++
1 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index fa3486d..dd20b19 100644
--- a/kernel/x86/mmu.c
+++ a/kernel/x86/mmu.c
@@ -1593,6 +1593,15 @@ static int set_spte(struct kvm_vcpu *vcpu, u64 *shadow_pte,
spte |= PT_WRITABLE_MASK;
+ /*
+ * Optimization: for pte sync, if spte was writable the hash
+ * lookup is unnecessary (and expensive). Write protection
+ * is responsibility of mmu_get_page / kvm_sync_page.
+ * Same reasoning can be applied to dirty page accounting.
+ */
+ if (!can_unsync && is_writeble_pte(*shadow_pte))
+ goto set_pte;
+
if (mmu_need_write_protect(vcpu, gfn, can_unsync)) {
pgprintk("%s: found shadow page for %lx, marking ro\n",
__func__, gfn);
--
1.5.6
++++++ kvm-pre81-kernel-0051-KVM-Really-remove-a-slot-when-a-user-ask-us-so.patch ++++++
>From 58e235dc112a8d0cc309af0f2e526087235ab633 Mon Sep 17 00:00:00 2001
From: Glauber Costa <glommer(a)redhat.com>
Date: Wed, 3 Dec 2008 13:40:51 -0200
Subject: [PATCH] KVM: Really remove a slot when a user ask us so
Right now, KVM does not remove a slot when we do a
register ioctl for size 0 (would be the expected behaviour).
Instead, we only mark it as empty, but keep all bitmaps
and allocated data structures present. It completely
nullifies our chances of reusing that same slot again
for mapping a different piece of memory.
In this patch, we destroy rmaps, and vfree() the
pointers that used to hold the dirty bitmap, rmap
and lpage_info structures.
Signed-off-by: Glauber Costa <glommer(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
virt/kvm/kvm_main.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index e41d39d..fd9cc79 100644
--- a/kernel/x86/kvm_main.c
+++ a/kernel/x86/kvm_main.c
@@ -1020,7 +1020,10 @@ int __kvm_set_memory_region(struct kvm *kvm,
goto out_free;
}
- kvm_free_physmem_slot(&old, &new);
+ kvm_free_physmem_slot(&old, npages ? &new : NULL);
+ /* Slot deletion case: we have to update the current slot */
+ if (!npages)
+ *memslot = old;
#ifdef CONFIG_DMAR
/* map the pages in iommu page table */
r = kvm_iommu_map_pages(kvm, base_gfn, npages);
--
1.5.6
++++++ kvm-pre81-kernel-0058-KVM-MMU-use-page-array-in-unsync-walk.patch ++++++
>From 82074c7dd0c4518c835fbefed00477488869b6cf Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Mon, 1 Dec 2008 22:32:02 -0200
Subject: [PATCH] KVM: MMU: use page array in unsync walk
Instead of invoking the handler directly collect pages into
an array so the caller can work with it.
Simplifies TLB flush collapsing.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 195 +++++++++++++++++++++++++++++++++++++---------------
1 files changed, 140 insertions(+), 55 deletions(-)
Index: kvm-78/kernel/x86/mmu.c
===================================================================
--- kvm-78.orig/kernel/x86/mmu.c
+++ kvm-78/kernel/x86/mmu.c
@@ -936,8 +936,9 @@ static void kvm_mmu_update_unsync_bitmap
struct kvm_mmu_page *sp = page_header(__pa(spte));
index = spte - sp->spt;
- __set_bit(index, sp->unsync_child_bitmap);
- sp->unsync_children = 1;
+ if (!__test_and_set_bit(index, sp->unsync_child_bitmap))
+ sp->unsync_children++;
+ WARN_ON(!sp->unsync_children);
}
static void kvm_mmu_update_parents_unsync(struct kvm_mmu_page *sp)
@@ -964,7 +965,6 @@ static void kvm_mmu_update_parents_unsyn
static int unsync_walk_fn(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp)
{
- sp->unsync_children = 1;
kvm_mmu_update_parents_unsync(sp);
return 1;
}
@@ -995,18 +995,41 @@ static void nonpaging_invlpg(struct kvm_
{
}
+#define KVM_PAGE_ARRAY_NR 16
+
+struct kvm_mmu_pages {
+ struct mmu_page_and_offset {
+ struct kvm_mmu_page *sp;
+ unsigned int idx;
+ } page[KVM_PAGE_ARRAY_NR];
+ unsigned int nr;
+};
+
#define for_each_unsync_children(bitmap, idx) \
for (idx = find_first_bit(bitmap, 512); \
idx < 512; \
idx = find_next_bit(bitmap, 512, idx+1))
-static int mmu_unsync_walk(struct kvm_mmu_page *sp,
- struct kvm_unsync_walk *walker)
+int mmu_pages_add(struct kvm_mmu_pages *pvec, struct kvm_mmu_page *sp,
+ int idx)
{
- int i, ret;
+ int i;
- if (!sp->unsync_children)
- return 0;
+ if (sp->unsync)
+ for (i=0; i < pvec->nr; i++)
+ if (pvec->page[i].sp == sp)
+ return 0;
+
+ pvec->page[pvec->nr].sp = sp;
+ pvec->page[pvec->nr].idx = idx;
+ pvec->nr++;
+ return (pvec->nr == KVM_PAGE_ARRAY_NR);
+}
+
+static int __mmu_unsync_walk(struct kvm_mmu_page *sp,
+ struct kvm_mmu_pages *pvec)
+{
+ int i, ret, nr_unsync_leaf = 0;
for_each_unsync_children(sp->unsync_child_bitmap, i) {
u64 ent = sp->spt[i];
@@ -1016,17 +1039,22 @@ static int mmu_unsync_walk(struct kvm_mm
child = page_header(ent & PT64_BASE_ADDR_MASK);
if (child->unsync_children) {
- ret = mmu_unsync_walk(child, walker);
- if (ret)
+ if (mmu_pages_add(pvec, child, i))
+ return -ENOSPC;
+
+ ret = __mmu_unsync_walk(child, pvec);
+ if (!ret)
+ __clear_bit(i, sp->unsync_child_bitmap);
+ else if (ret > 0)
+ nr_unsync_leaf += ret;
+ else
return ret;
- __clear_bit(i, sp->unsync_child_bitmap);
}
if (child->unsync) {
- ret = walker->entry(child, walker);
- __clear_bit(i, sp->unsync_child_bitmap);
- if (ret)
- return ret;
+ nr_unsync_leaf++;
+ if (mmu_pages_add(pvec, child, i))
+ return -ENOSPC;
}
}
}
@@ -1034,7 +1062,17 @@ static int mmu_unsync_walk(struct kvm_mm
if (find_first_bit(sp->unsync_child_bitmap, 512) == 512)
sp->unsync_children = 0;
- return 0;
+ return nr_unsync_leaf;
+}
+
+static int mmu_unsync_walk(struct kvm_mmu_page *sp,
+ struct kvm_mmu_pages *pvec)
+{
+ if (!sp->unsync_children)
+ return 0;
+
+ mmu_pages_add(pvec, sp, 0);
+ return __mmu_unsync_walk(sp, pvec);
}
static struct kvm_mmu_page *kvm_mmu_lookup_page(struct kvm *kvm, gfn_t gfn)
@@ -1084,30 +1122,81 @@ static int kvm_sync_page(struct kvm_vcpu
return 0;
}
-struct sync_walker {
- struct kvm_vcpu *vcpu;
- struct kvm_unsync_walk walker;
+struct mmu_page_path {
+ struct kvm_mmu_page *parent[PT64_ROOT_LEVEL-1];
+ unsigned int idx[PT64_ROOT_LEVEL-1];
};
-static int mmu_sync_fn(struct kvm_mmu_page *sp, struct kvm_unsync_walk *walk)
+#define for_each_sp(pvec, sp, parents, i) \
+ for (i = mmu_pages_next(&pvec, &parents, -1), \
+ sp = pvec.page[i].sp; \
+ i < pvec.nr && ({ sp = pvec.page[i].sp; 1;}); \
+ i = mmu_pages_next(&pvec, &parents, i))
+
+int mmu_pages_next(struct kvm_mmu_pages *pvec, struct mmu_page_path *parents,
+ int i)
+{
+ int n;
+
+ for (n = i+1; n < pvec->nr; n++) {
+ struct kvm_mmu_page *sp = pvec->page[n].sp;
+
+ if (sp->role.level == PT_PAGE_TABLE_LEVEL) {
+ parents->idx[0] = pvec->page[n].idx;
+ return n;
+ }
+
+ parents->parent[sp->role.level-2] = sp;
+ parents->idx[sp->role.level-1] = pvec->page[n].idx;
+ }
+
+ return n;
+}
+
+void mmu_pages_clear_parents(struct mmu_page_path *parents)
{
- struct sync_walker *sync_walk = container_of(walk, struct sync_walker,
- walker);
- struct kvm_vcpu *vcpu = sync_walk->vcpu;
+ struct kvm_mmu_page *sp;
+ unsigned int level = 0;
+
+ do {
+ unsigned int idx = parents->idx[level];
+
+ sp = parents->parent[level];
+ if (!sp)
+ return;
- kvm_sync_page(vcpu, sp);
- return (need_resched() || spin_needbreak(&vcpu->kvm->mmu_lock));
+ --sp->unsync_children;
+ WARN_ON((int)sp->unsync_children < 0);
+ __clear_bit(idx, sp->unsync_child_bitmap);
+ level++;
+ } while (level < PT64_ROOT_LEVEL-1 && !sp->unsync_children);
}
-static void mmu_sync_children(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp)
+static void kvm_mmu_pages_init(struct kvm_mmu_page *parent,
+ struct mmu_page_path *parents,
+ struct kvm_mmu_pages *pvec)
{
- struct sync_walker walker = {
- .walker = { .entry = mmu_sync_fn, },
- .vcpu = vcpu,
- };
+ parents->parent[parent->role.level-1] = NULL;
+ pvec->nr = 0;
+}
+
+static void mmu_sync_children(struct kvm_vcpu *vcpu,
+ struct kvm_mmu_page *parent)
+{
+ int i;
+ struct kvm_mmu_page *sp;
+ struct mmu_page_path parents;
+ struct kvm_mmu_pages pages;
- while (mmu_unsync_walk(sp, &walker.walker))
+ kvm_mmu_pages_init(parent, &parents, &pages);
+ while (mmu_unsync_walk(parent, &pages)) {
+ for_each_sp(pages, sp, parents, i) {
+ kvm_sync_page(vcpu, sp);
+ mmu_pages_clear_parents(&parents);
+ }
cond_resched_lock(&vcpu->kvm->mmu_lock);
+ kvm_mmu_pages_init(parent, &parents, &pages);
+ }
}
static struct kvm_mmu_page *kvm_mmu_get_page(struct kvm_vcpu *vcpu,
@@ -1273,33 +1362,29 @@ static void kvm_mmu_unlink_parents(struc
}
}
-struct zap_walker {
- struct kvm_unsync_walk walker;
- struct kvm *kvm;
- int zapped;
-};
-
-static int mmu_zap_fn(struct kvm_mmu_page *sp, struct kvm_unsync_walk *walk)
+static int mmu_zap_unsync_children(struct kvm *kvm,
+ struct kvm_mmu_page *parent)
{
- struct zap_walker *zap_walk = container_of(walk, struct zap_walker,
- walker);
- kvm_mmu_zap_page(zap_walk->kvm, sp);
- zap_walk->zapped = 1;
- return 0;
-}
+ int i, zapped = 0;
+ struct mmu_page_path parents;
+ struct kvm_mmu_pages pages;
-static int mmu_zap_unsync_children(struct kvm *kvm, struct kvm_mmu_page *sp)
-{
- struct zap_walker walker = {
- .walker = { .entry = mmu_zap_fn, },
- .kvm = kvm,
- .zapped = 0,
- };
-
- if (sp->role.level == PT_PAGE_TABLE_LEVEL)
+ if (parent->role.level == PT_PAGE_TABLE_LEVEL)
return 0;
- mmu_unsync_walk(sp, &walker.walker);
- return walker.zapped;
+
+ kvm_mmu_pages_init(parent, &parents, &pages);
+ while (mmu_unsync_walk(parent, &pages)) {
+ struct kvm_mmu_page *sp;
+
+ for_each_sp(pages, sp, parents, i) {
+ kvm_mmu_zap_page(kvm, sp);
+ mmu_pages_clear_parents(&parents);
+ }
+ zapped += pages.nr;
+ kvm_mmu_pages_init(parent, &parents, &pages);
+ }
+
+ return zapped;
}
static int kvm_mmu_zap_page(struct kvm *kvm, struct kvm_mmu_page *sp)
Index: kvm-78/kernel/include/asm-x86/kvm_host.h
===================================================================
--- kvm-78.orig/kernel/include/asm-x86/kvm_host.h
+++ kvm-78/kernel/include/asm-x86/kvm_host.h
@@ -228,7 +228,7 @@ struct kvm_mmu_page {
int multimapped; /* More than one parent_pte? */
int root_count; /* Currently serving as active root */
bool unsync;
- bool unsync_children;
+ unsigned int unsync_children;
union {
u64 *parent_pte; /* !multimapped */
struct hlist_head parent_ptes; /* multimapped, kvm_pte_chain */
++++++ kvm-pre81-kernel-0059-KVM-MMU-collapse-remote-TLB-flushes-on-root-sync.patch ++++++
>From bb7011357ce71c3c0b736c76dc6c9f542fce0e8e Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Mon, 1 Dec 2008 22:32:03 -0200
Subject: [PATCH] KVM: MMU: collapse remote TLB flushes on root sync
Collapse remote TLB flushes on root sync.
kernbench is 2.7% faster on 4-way guest. Improvements have been seen
with other loads such as AIM7.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 19 ++++++++++++++-----
1 files changed, 14 insertions(+), 5 deletions(-)
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 7ce92f7..58c35de 100644
--- a/kernel/x86/mmu.c
+++ a/kernel/x86/mmu.c
@@ -621,7 +621,7 @@ static u64 *rmap_next(struct kvm *kvm, unsigned long *rmapp, u64 *spte)
return NULL;
}
-static void rmap_write_protect(struct kvm *kvm, u64 gfn)
+static int rmap_write_protect(struct kvm *kvm, u64 gfn)
{
unsigned long *rmapp;
u64 *spte;
@@ -667,8 +667,7 @@ static void rmap_write_protect(struct kvm *kvm, u64 gfn)
spte = rmap_next(kvm, rmapp, spte);
}
- if (write_protected)
- kvm_flush_remote_tlbs(kvm);
+ return write_protected;
}
static int kvm_unmap_rmapp(struct kvm *kvm, unsigned long *rmapp)
@@ -1083,7 +1082,8 @@ static int kvm_sync_page(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp)
return 1;
}
- rmap_write_protect(vcpu->kvm, sp->gfn);
+ if (rmap_write_protect(vcpu->kvm, sp->gfn))
+ kvm_flush_remote_tlbs(vcpu->kvm);
kvm_unlink_unsync_page(vcpu->kvm, sp);
if (vcpu->arch.mmu.sync_page(vcpu, sp)) {
kvm_mmu_zap_page(vcpu->kvm, sp);
@@ -1162,6 +1162,14 @@ static void mmu_sync_children(struct kvm_vcpu *vcpu,
kvm_mmu_pages_init(parent, &parents, &pages);
while (mmu_unsync_walk(parent, &pages)) {
+ int protected = 0;
+
+ for_each_sp(pages, sp, parents, i)
+ protected |= rmap_write_protect(vcpu->kvm, sp->gfn);
+
+ if (protected)
+ kvm_flush_remote_tlbs(vcpu->kvm);
+
for_each_sp(pages, sp, parents, i) {
kvm_sync_page(vcpu, sp);
mmu_pages_clear_parents(&parents);
@@ -1226,7 +1234,8 @@ static struct kvm_mmu_page *kvm_mmu_get_page(struct kvm_vcpu *vcpu,
sp->role = role;
hlist_add_head(&sp->hash_link, bucket);
if (!metaphysical) {
- rmap_write_protect(vcpu->kvm, gfn);
+ if (rmap_write_protect(vcpu->kvm, gfn))
+ kvm_flush_remote_tlbs(vcpu->kvm);
account_shadowed(vcpu->kvm, gfn);
}
if (shadow_trap_nonpresent_pte != shadow_notrap_nonpresent_pte)
--
1.5.6
++++++ kvm-pre81-kernel-0060-KVM-MMU-skip-global-pgtables-on-sync-due-to-cr3-sw.patch ++++++
>From 6364a3918cb5c28376849e7fca3e09bd66b859f3 Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Mon, 1 Dec 2008 22:32:04 -0200
Subject: [PATCH] KVM: MMU: skip global pgtables on sync due to cr3 switch
Skip syncing global pages on cr3 switch (but not on cr4/cr0). This is
important for Linux 32-bit guests with PAE, where the kmap page is
marked as global.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 53 +++++++++++++++++++++++++++++++++++++++-----
arch/x86/kvm/paging_tmpl.h | 10 +++++---
arch/x86/kvm/x86.c | 4 +++
3 files changed, 57 insertions(+), 10 deletions(-)
diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
index 93d0aed..65b1ed2 100644
--- a/kernel/include/asm-x86/kvm_host.h
+++ b/kernel/include/asm-x86/kvm_host.h
@@ -182,6 +182,8 @@ struct kvm_mmu_page {
struct list_head link;
struct hlist_node hash_link;
+ struct list_head oos_link;
+
/*
* The following two entries are used to key the shadow page in the
* hash table.
@@ -200,6 +202,7 @@ struct kvm_mmu_page {
int multimapped; /* More than one parent_pte? */
int root_count; /* Currently serving as active root */
bool unsync;
+ bool global;
unsigned int unsync_children;
union {
u64 *parent_pte; /* !multimapped */
@@ -356,6 +359,7 @@ struct kvm_arch{
*/
struct list_head active_mmu_pages;
struct list_head assigned_dev_head;
+ struct list_head oos_global_pages;
struct dmar_domain *intel_iommu_domain;
struct kvm_pic *vpic;
struct kvm_ioapic *vioapic;
@@ -385,6 +389,7 @@ struct kvm_vm_stat {
u32 mmu_recycled;
u32 mmu_cache_miss;
u32 mmu_unsync;
+ u32 mmu_unsync_global;
u32 remote_tlb_flush;
u32 lpages;
};
@@ -603,6 +608,7 @@ void __kvm_mmu_free_some_pages(struct kvm_vcpu *vcpu);
int kvm_mmu_load(struct kvm_vcpu *vcpu);
void kvm_mmu_unload(struct kvm_vcpu *vcpu);
void kvm_mmu_sync_roots(struct kvm_vcpu *vcpu);
+void kvm_mmu_sync_global(struct kvm_vcpu *vcpu);
int kvm_emulate_hypercall(struct kvm_vcpu *vcpu);
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 58c35de..cbac9e4 100644
--- a/kernel/x86/mmu.c
+++ a/kernel/x86/mmu.c
@@ -793,9 +793,11 @@ static struct kvm_mmu_page *kvm_mmu_alloc_page(struct kvm_vcpu *vcpu,
sp->gfns = mmu_memory_cache_alloc(&vcpu->arch.mmu_page_cache, PAGE_SIZE);
set_page_private(virt_to_page(sp->spt), (unsigned long)sp);
list_add(&sp->link, &vcpu->kvm->arch.active_mmu_pages);
+ INIT_LIST_HEAD(&sp->oos_link);
ASSERT(is_empty_shadow_page(sp->spt));
bitmap_zero(sp->slot_bitmap, KVM_MEMORY_SLOTS + KVM_PRIVATE_MEM_SLOTS);
sp->multimapped = 0;
+ sp->global = 1;
sp->parent_pte = parent_pte;
--vcpu->kvm->arch.n_free_mmu_pages;
return sp;
@@ -1066,10 +1068,18 @@ static struct kvm_mmu_page *kvm_mmu_lookup_page(struct kvm *kvm, gfn_t gfn)
return NULL;
}
+static void kvm_unlink_unsync_global(struct kvm *kvm, struct kvm_mmu_page *sp)
+{
+ list_del(&sp->oos_link);
+ --kvm->stat.mmu_unsync_global;
+}
+
static void kvm_unlink_unsync_page(struct kvm *kvm, struct kvm_mmu_page *sp)
{
WARN_ON(!sp->unsync);
sp->unsync = 0;
+ if (sp->global)
+ kvm_unlink_unsync_global(kvm, sp);
--kvm->stat.mmu_unsync;
}
@@ -1615,9 +1625,15 @@ static int kvm_unsync_page(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp)
if (s->role.word != sp->role.word)
return 1;
}
- kvm_mmu_mark_parents_unsync(vcpu, sp);
++vcpu->kvm->stat.mmu_unsync;
sp->unsync = 1;
+
+ if (sp->global) {
+ list_add(&sp->oos_link, &vcpu->kvm->arch.oos_global_pages);
+ ++vcpu->kvm->stat.mmu_unsync_global;
+ } else
+ kvm_mmu_mark_parents_unsync(vcpu, sp);
+
mmu_convert_notrap(sp);
return 0;
}
@@ -1643,12 +1659,21 @@ static int mmu_need_write_protect(struct kvm_vcpu *vcpu, gfn_t gfn,
static int set_spte(struct kvm_vcpu *vcpu, u64 *shadow_pte,
unsigned pte_access, int user_fault,
int write_fault, int dirty, int largepage,
- gfn_t gfn, pfn_t pfn, bool speculative,
+ int global, gfn_t gfn, pfn_t pfn, bool speculative,
bool can_unsync)
{
u64 spte;
int ret = 0;
u64 mt_mask = shadow_mt_mask;
+ struct kvm_mmu_page *sp = page_header(__pa(shadow_pte));
+
+ if (!global && sp->global) {
+ sp->global = 0;
+ if (sp->unsync) {
+ kvm_unlink_unsync_global(vcpu->kvm, sp);
+ kvm_mmu_mark_parents_unsync(vcpu, sp);
+ }
+ }
/*
* We don't set the accessed bit, since we sometimes want to see
@@ -1717,8 +1742,8 @@ set_pte:
static void mmu_set_spte(struct kvm_vcpu *vcpu, u64 *shadow_pte,
unsigned pt_access, unsigned pte_access,
int user_fault, int write_fault, int dirty,
- int *ptwrite, int largepage, gfn_t gfn,
- pfn_t pfn, bool speculative)
+ int *ptwrite, int largepage, int global,
+ gfn_t gfn, pfn_t pfn, bool speculative)
{
int was_rmapped = 0;
int was_writeble = is_writeble_pte(*shadow_pte);
@@ -1751,7 +1776,7 @@ static void mmu_set_spte(struct kvm_vcpu *vcpu, u64 *shadow_pte,
}
}
if (set_spte(vcpu, shadow_pte, pte_access, user_fault, write_fault,
- dirty, largepage, gfn, pfn, speculative, true)) {
+ dirty, largepage, global, gfn, pfn, speculative, true)) {
if (write_fault)
*ptwrite = 1;
kvm_x86_ops->tlb_flush(vcpu);
@@ -1808,7 +1833,7 @@ static int direct_map_entry(struct kvm_shadow_walk *_walk,
|| (walk->largepage && level == PT_DIRECTORY_LEVEL)) {
mmu_set_spte(vcpu, sptep, ACC_ALL, ACC_ALL,
0, walk->write, 1, &walk->pt_write,
- walk->largepage, gfn, walk->pfn, false);
+ walk->largepage, 0, gfn, walk->pfn, false);
++vcpu->stat.pf_fixed;
return 1;
}
@@ -1995,6 +2020,15 @@ static void mmu_sync_roots(struct kvm_vcpu *vcpu)
}
}
+static void mmu_sync_global(struct kvm_vcpu *vcpu)
+{
+ struct kvm *kvm = vcpu->kvm;
+ struct kvm_mmu_page *sp, *n;
+
+ list_for_each_entry_safe(sp, n, &kvm->arch.oos_global_pages, oos_link)
+ kvm_sync_page(vcpu, sp);
+}
+
void kvm_mmu_sync_roots(struct kvm_vcpu *vcpu)
{
spin_lock(&vcpu->kvm->mmu_lock);
@@ -2002,6 +2036,13 @@ void kvm_mmu_sync_roots(struct kvm_vcpu *vcpu)
spin_unlock(&vcpu->kvm->mmu_lock);
}
+void kvm_mmu_sync_global(struct kvm_vcpu *vcpu)
+{
+ spin_lock(&vcpu->kvm->mmu_lock);
+ mmu_sync_global(vcpu);
+ spin_unlock(&vcpu->kvm->mmu_lock);
+}
+
static gpa_t nonpaging_gva_to_gpa(struct kvm_vcpu *vcpu, gva_t vaddr)
{
return vaddr;
diff --git a/arch/x86/kvm/paging_tmpl.h b/arch/x86/kvm/paging_tmpl.h
index 84eee43..e644d81 100644
--- a/kernel/x86/paging_tmpl.h
+++ a/kernel/x86/paging_tmpl.h
@@ -274,7 +274,8 @@ static void FNAME(update_pte)(struct kvm_vcpu *vcpu, struct kvm_mmu_page *page,
return;
kvm_get_pfn(pfn);
mmu_set_spte(vcpu, spte, page->role.access, pte_access, 0, 0,
- gpte & PT_DIRTY_MASK, NULL, largepage, gpte_to_gfn(gpte),
+ gpte & PT_DIRTY_MASK, NULL, largepage,
+ gpte & PT_GLOBAL_MASK, gpte_to_gfn(gpte),
pfn, true);
}
@@ -301,8 +302,9 @@ static int FNAME(shadow_walk_entry)(struct kvm_shadow_walk *_sw,
mmu_set_spte(vcpu, sptep, access, gw->pte_access & access,
sw->user_fault, sw->write_fault,
gw->ptes[gw->level-1] & PT_DIRTY_MASK,
- sw->ptwrite, sw->largepage, gw->gfn, sw->pfn,
- false);
+ sw->ptwrite, sw->largepage,
+ gw->ptes[gw->level-1] & PT_GLOBAL_MASK,
+ gw->gfn, sw->pfn, false);
sw->sptep = sptep;
return 1;
}
@@ -580,7 +582,7 @@ static int FNAME(sync_page)(struct kvm_vcpu *vcpu, struct kvm_mmu_page *sp)
nr_present++;
pte_access = sp->role.access & FNAME(gpte_access)(vcpu, gpte);
set_spte(vcpu, &sp->spt[i], pte_access, 0, 0,
- is_dirty_pte(gpte), 0, gfn,
+ is_dirty_pte(gpte), 0, gpte & PT_GLOBAL_MASK, gfn,
spte_to_pfn(sp->spt[i]), true, false);
}
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index 7a2aeba..774db00 100644
--- a/kernel/x86/x86.c
+++ a/kernel/x86/x86.c
@@ -104,6 +104,7 @@ struct kvm_stats_debugfs_item debugfs_entries[] = {
{ "mmu_recycled", VM_STAT(mmu_recycled) },
{ "mmu_cache_miss", VM_STAT(mmu_cache_miss) },
{ "mmu_unsync", VM_STAT(mmu_unsync) },
+ { "mmu_unsync_global", VM_STAT(mmu_unsync_global) },
{ "remote_tlb_flush", VM_STAT(remote_tlb_flush) },
{ "largepages", VM_STAT(lpages) },
{ NULL }
@@ -315,6 +316,7 @@ void kvm_set_cr0(struct kvm_vcpu *vcpu, unsigned long cr0)
kvm_x86_ops->set_cr0(vcpu, cr0);
vcpu->arch.cr0 = cr0;
+ kvm_mmu_sync_global(vcpu);
kvm_mmu_reset_context(vcpu);
return;
}
@@ -358,6 +360,7 @@ void kvm_set_cr4(struct kvm_vcpu *vcpu, unsigned long cr4)
}
kvm_x86_ops->set_cr4(vcpu, cr4);
vcpu->arch.cr4 = cr4;
+ kvm_mmu_sync_global(vcpu);
kvm_mmu_reset_context(vcpu);
}
EXPORT_SYMBOL_GPL(kvm_set_cr4);
@@ -4113,6 +4116,7 @@ struct kvm *kvm_arch_create_vm(void)
return ERR_PTR(-ENOMEM);
INIT_LIST_HEAD(&kvm->arch.active_mmu_pages);
+ INIT_LIST_HEAD(&kvm->arch.oos_global_pages);
INIT_LIST_HEAD(&kvm->arch.assigned_dev_head);
/* Reserve bit 0 of irq_sources_bitmap for userspace irq source */
--
1.5.6
++++++ kvm-pre81-kernel-0061-KVM-MMU-prepopulate-the-shadow-on-invlpg.patch ++++++
>From 685313f4d6d7850b37a2def5d242b2f6dde68e3b Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Mon, 1 Dec 2008 22:32:05 -0200
Subject: [PATCH] KVM: MMU: prepopulate the shadow on invlpg
If the guest executes invlpg, peek into the pagetable and attempt to
prepopulate the shadow entry.
Also stop dirty fault updates from interfering with the fork detector.
2% improvement on RHEL3/AIM7.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 25 +++++++++++++------------
arch/x86/kvm/paging_tmpl.h | 25 ++++++++++++++++++++++++-
arch/x86/kvm/x86.c | 2 +-
3 files changed, 38 insertions(+), 14 deletions(-)
Index: kvm-78/kernel/x86/mmu.c
===================================================================
--- kvm-78.orig/kernel/x86/mmu.c
+++ kvm-78/kernel/x86/mmu.c
@@ -2469,7 +2469,8 @@ static void kvm_mmu_access_page(struct k
}
void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_t gpa,
- const u8 *new, int bytes)
+ const u8 *new, int bytes,
+ bool guest_initiated)
{
gfn_t gfn = gpa >> PAGE_SHIFT;
struct kvm_mmu_page *sp;
@@ -2495,15 +2496,17 @@ void kvm_mmu_pte_write(struct kvm_vcpu *
kvm_mmu_free_some_pages(vcpu);
++vcpu->kvm->stat.mmu_pte_write;
kvm_mmu_audit(vcpu, "pre pte write");
- if (gfn == vcpu->arch.last_pt_write_gfn
- && !last_updated_pte_accessed(vcpu)) {
- ++vcpu->arch.last_pt_write_count;
- if (vcpu->arch.last_pt_write_count >= 3)
- flooded = 1;
- } else {
- vcpu->arch.last_pt_write_gfn = gfn;
- vcpu->arch.last_pt_write_count = 1;
- vcpu->arch.last_pte_updated = NULL;
+ if (guest_initiated) {
+ if (gfn == vcpu->arch.last_pt_write_gfn
+ && !last_updated_pte_accessed(vcpu)) {
+ ++vcpu->arch.last_pt_write_count;
+ if (vcpu->arch.last_pt_write_count >= 3)
+ flooded = 1;
+ } else {
+ vcpu->arch.last_pt_write_gfn = gfn;
+ vcpu->arch.last_pt_write_count = 1;
+ vcpu->arch.last_pte_updated = NULL;
+ }
}
index = kvm_page_table_hashfn(gfn);
bucket = &vcpu->kvm->arch.mmu_page_hash[index];
@@ -2643,9 +2646,7 @@ EXPORT_SYMBOL_GPL(kvm_mmu_page_fault);
void kvm_mmu_invlpg(struct kvm_vcpu *vcpu, gva_t gva)
{
- spin_lock(&vcpu->kvm->mmu_lock);
vcpu->arch.mmu.invlpg(vcpu, gva);
- spin_unlock(&vcpu->kvm->mmu_lock);
kvm_mmu_flush_tlb(vcpu);
++vcpu->stat.invlpg;
}
Index: kvm-78/kernel/x86/paging_tmpl.h
===================================================================
--- kvm-78.orig/kernel/x86/paging_tmpl.h
+++ kvm-78/kernel/x86/paging_tmpl.h
@@ -82,6 +82,7 @@ struct shadow_walker {
int *ptwrite;
pfn_t pfn;
u64 *sptep;
+ gpa_t pte_gpa;
};
static gfn_t gpte_to_gfn(pt_element_t gpte)
@@ -222,7 +223,7 @@ walk:
if (ret)
goto walk;
pte |= PT_DIRTY_MASK;
- kvm_mmu_pte_write(vcpu, pte_gpa, (u8 *)&pte, sizeof(pte));
+ kvm_mmu_pte_write(vcpu, pte_gpa, (u8 *)&pte, sizeof(pte), 0);
walker->ptes[walker->level - 1] = pte;
}
@@ -468,8 +469,15 @@ static int FNAME(shadow_invlpg_entry)(st
struct kvm_vcpu *vcpu, u64 addr,
u64 *sptep, int level)
{
+ struct shadow_walker *sw =
+ container_of(_sw, struct shadow_walker, walker);
if (level == PT_PAGE_TABLE_LEVEL) {
+ struct kvm_mmu_page *sp = page_header(__pa(sptep));
+
+ sw->pte_gpa = (sp->gfn << PAGE_SHIFT);
+ sw->pte_gpa += (sptep - sp->spt) * sizeof(pt_element_t);
+
if (is_shadow_present_pte(*sptep))
rmap_remove(vcpu->kvm, sptep);
set_shadow_pte(sptep, shadow_trap_nonpresent_pte);
@@ -482,11 +490,26 @@ static int FNAME(shadow_invlpg_entry)(st
static void FNAME(invlpg)(struct kvm_vcpu *vcpu, gva_t gva)
{
+ pt_element_t gpte;
struct shadow_walker walker = {
.walker = { .entry = FNAME(shadow_invlpg_entry), },
+ .pte_gpa = -1,
};
+ spin_lock(&vcpu->kvm->mmu_lock);
walk_shadow(&walker.walker, vcpu, gva);
+ spin_unlock(&vcpu->kvm->mmu_lock);
+ if (walker.pte_gpa == -1)
+ return;
+ if (kvm_read_guest_atomic(vcpu->kvm, walker.pte_gpa, &gpte,
+ sizeof(pt_element_t)))
+ return;
+ if (is_present_pte(gpte) && (gpte & PT_ACCESSED_MASK)) {
+ if (mmu_topup_memory_caches(vcpu))
+ return;
+ kvm_mmu_pte_write(vcpu, walker.pte_gpa, (const u8 *)&gpte,
+ sizeof(pt_element_t), 0);
+ }
}
static gpa_t FNAME(gva_to_gpa)(struct kvm_vcpu *vcpu, gva_t vaddr)
Index: kvm-78/kernel/x86/x86.c
===================================================================
--- kvm-78.orig/kernel/x86/x86.c
+++ kvm-78/kernel/x86/x86.c
@@ -2092,7 +2092,7 @@ int emulator_write_phys(struct kvm_vcpu
ret = kvm_write_guest(vcpu->kvm, gpa, val, bytes);
if (ret < 0)
return 0;
- kvm_mmu_pte_write(vcpu, gpa, val, bytes);
+ kvm_mmu_pte_write(vcpu, gpa, val, bytes, 1);
return 1;
}
Index: kvm-78/kernel/include/asm-x86/kvm_host.h
===================================================================
--- kvm-78.orig/kernel/include/asm-x86/kvm_host.h
+++ kvm-78/kernel/include/asm-x86/kvm_host.h
@@ -631,7 +631,8 @@ unsigned long segment_base(u16 selector)
void kvm_mmu_flush_tlb(struct kvm_vcpu *vcpu);
void kvm_mmu_pte_write(struct kvm_vcpu *vcpu, gpa_t gpa,
- const u8 *new, int bytes);
+ const u8 *new, int bytes,
+ bool guest_initiated);
int kvm_mmu_unprotect_page_virt(struct kvm_vcpu *vcpu, gva_t gva);
void __kvm_mmu_free_some_pages(struct kvm_vcpu *vcpu);
int kvm_mmu_load(struct kvm_vcpu *vcpu);
++++++ kvm-pre81-kernel-0066-KVM-Advertise-the-bug-in-memory-region-destruction.patch ++++++
>From 70cee7ac32b61abc29687264b74fa514719a1d44 Mon Sep 17 00:00:00 2001
From: Avi Kivity <avi(a)redhat.com>
Date: Mon, 8 Dec 2008 18:25:27 +0200
Subject: [PATCH] KVM: Advertise the bug in memory region destruction as fixed
Userspace might need to act differently.
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
virt/kvm/kvm_main.c | 13 ++++++++++++-
1 files changed, 12 insertions(+), 1 deletions(-)
Index: kvm-78/kernel/x86/kvm_main.c
===================================================================
--- kvm-78.orig/kernel/x86/kvm_main.c
+++ kvm-78/kernel/x86/kvm_main.c
@@ -1757,6 +1757,17 @@ static int kvm_dev_ioctl_create_vm(void)
return fd;
}
+static long kvm_dev_ioctl_check_extension_generic(long arg)
+{
+ switch (arg) {
+ case KVM_CAP_DESTROY_MEMORY_REGION_WORKS:
+ return 1;
+ default:
+ break;
+ }
+ return kvm_dev_ioctl_check_extension(arg);
+}
+
static long kvm_dev_ioctl(struct file *filp,
unsigned int ioctl, unsigned long arg)
{
@@ -1776,7 +1787,7 @@ static long kvm_dev_ioctl(struct file *f
r = kvm_dev_ioctl_create_vm();
break;
case KVM_CHECK_EXTENSION:
- r = kvm_dev_ioctl_check_extension(arg);
+ r = kvm_dev_ioctl_check_extension_generic(arg);
break;
case KVM_GET_VCPU_MMAP_SIZE:
r = -EINVAL;
Index: kvm-78/kernel/include/linux/kvm.h
===================================================================
--- kvm-78.orig/kernel/include/linux/kvm.h
+++ kvm-78/kernel/include/linux/kvm.h
@@ -420,6 +420,7 @@ struct kvm_trace_rec {
#endif
#define KVM_CAP_IOMMU 18
#define KVM_CAP_NMI 19
+#define KVM_CAP_DESTROY_MEMORY_REGION_WORKS 21
/*
* ioctls for VM fds
++++++ kvm-pre81-kernel-0067-KVM-Consolidate-userspace-memory-capability-reporti.patch ++++++
>From f22bc9c40488ba7d68b744b3dfb388b0fdaaa079 Mon Sep 17 00:00:00 2001
From: Avi Kivity <avi(a)redhat.com>
Date: Mon, 8 Dec 2008 18:29:29 +0200
Subject: [PATCH] KVM: Consolidate userspace memory capability reporting into common code
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/x86.c | 1 -
virt/kvm/kvm_main.c | 1 +
2 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index ba10287..10302d3 100644
--- a/kernel/x86/x86.c
+++ a/kernel/x86/x86.c
@@ -964,7 +964,6 @@ int kvm_dev_ioctl_check_extension(long ext)
case KVM_CAP_IRQCHIP:
case KVM_CAP_HLT:
case KVM_CAP_MMU_SHADOW_CACHE_CONTROL:
- case KVM_CAP_USER_MEMORY:
case KVM_CAP_SET_TSS_ADDR:
case KVM_CAP_EXT_CPUID:
case KVM_CAP_CLOCKSOURCE:
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index e066eb1..eb70ca6 100644
--- a/kernel/x86/kvm_main.c
+++ a/kernel/x86/kvm_main.c
@@ -1908,6 +1908,7 @@ static int kvm_dev_ioctl_create_vm(void)
static long kvm_dev_ioctl_check_extension_generic(long arg)
{
switch (arg) {
+ case KVM_CAP_USER_MEMORY:
case KVM_CAP_DESTROY_MEMORY_REGION_WORKS:
return 1;
default:
--
1.5.6
++++++ kvm-pre81-kernel-0068-KVM-MMU-check-for-present-pdptr-shadow-page-in-wal.patch ++++++
>From 2f1be8b8b60d24e7f12002650544d0d95550f7cd Mon Sep 17 00:00:00 2001
From: Marcelo Tosatti <mtosatti(a)redhat.com>
Date: Tue, 9 Dec 2008 16:07:22 +0100
Subject: [PATCH] KVM: MMU: check for present pdptr shadow page in walk_shadow
walk_shadow assumes the caller verified validity of the pdptr pointer in
question, which is not the case for the invlpg handler.
Fixes oops during Solaris 10 install.
Signed-off-by: Marcelo Tosatti <mtosatti(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/mmu.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 863baf7..641c078 100644
--- a/kernel/x86/mmu.c
+++ a/kernel/x86/mmu.c
@@ -1269,6 +1269,8 @@ static int walk_shadow(struct kvm_shadow_walk *walker,
if (level == PT32E_ROOT_LEVEL) {
shadow_addr = vcpu->arch.mmu.pae_root[(addr >> 30) & 3];
shadow_addr &= PT64_BASE_ADDR_MASK;
+ if (!shadow_addr)
+ return 1;
--level;
}
--
1.5.6
++++++ kvm-pre81-kernel-0070-KVM-VMX-Fix-pending-NMI-vs.-IRQ-race-for-user-spac.patch ++++++
>From 387f7ca1b989fbde0e43d1e6aa4cbcf52dc5b730 Mon Sep 17 00:00:00 2001
From: Jan Kiszka <jan.kiszka(a)siemens.com>
Date: Mon, 24 Nov 2008 12:26:19 +0100
Subject: [PATCH] KVM: VMX: Fix pending NMI-vs.-IRQ race for user space irqchip
As with the kernel irqchip, don't allow an NMI to stomp over an already
injected IRQ; instead wait for the IRQ injection to be completed.
Signed-off-by: Jan Kiszka <jan.kiszka(a)siemens.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
arch/x86/kvm/vmx.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/arch/x86/kvm/vmx.c b/arch/x86/kvm/vmx.c
index e446f23..487e1dc 100644
--- a/kernel/x86/vmx.c
+++ a/kernel/x86/vmx.c
@@ -2486,7 +2486,9 @@ static void do_interrupt_requests(struct kvm_vcpu *vcpu,
vmx_update_window_states(vcpu);
if (vcpu->arch.nmi_pending && !vcpu->arch.nmi_injected) {
- if (vcpu->arch.nmi_window_open) {
+ if (vcpu->arch.interrupt.pending) {
+ enable_nmi_window(vcpu);
+ } else if (vcpu->arch.nmi_window_open) {
vcpu->arch.nmi_pending = false;
vcpu->arch.nmi_injected = true;
} else {
--
1.5.6
++++++ kvm-pre81-user-0019-Make-bottom-halves-more-robust.patch ++++++
>From c95c5158b1f6cdf411b76e2f48035128ee09a54d Mon Sep 17 00:00:00 2001
From: aliguori <aliguori>
Date: Fri, 31 Oct 2008 17:24:21 +0000
Subject: [PATCH] Make bottom halves more robust
Bottom halves are supposed to not complete until the next iteration of the main
loop. This is very important to ensure that guests can not cause stack
overflows in the block driver code. Right now, if you attempt to schedule a
bottom half within a bottom half callback, you will enter an infinite loop.
This patch uses the same logic that we use for the IOHandler loop to make the
bottom half processing robust in list manipulation while in a callback.
This patch also introduces idle scheduling for bottom halves. qemu_bh_poll()
returns an indication of whether any bottom halves were successfully executed.
qemu_aio_wait() uses this to immediately return if a bottom half was executed
instead of waiting for a completion notification.
qemu_bh_schedule_idle() works around this by not reporting the callback has
run in the qemu_bh_poll loop. qemu_aio_wait() probably needs some refactoring
but that would require a larger code audit. idle scheduling seems like a good
compromise.
Signed-off-by: Anthony Liguori <aliguori(a)us.ibm.com>
---
a/qemu/qemu-common.h | 1 +
a/qemu/vl.c | 60 ++++++++++++++++++++++++++++++++--------------------
2 files changed, 38 insertions(+), 23 deletions(-)
diff --git a/qemu/qemu-common.h b/qemu/qemu-common.h
index aca2674..0c6f4de 100644
--- a/qemu/qemu-common.h
+++ a/qemu/qemu-common.h
@@ -70,6 +70,7 @@ typedef void QEMUBHFunc(void *opaque);
QEMUBH *qemu_bh_new(QEMUBHFunc *cb, void *opaque);
void qemu_bh_schedule(QEMUBH *bh);
+void qemu_bh_schedule_idle(QEMUBH *bh);
void qemu_bh_cancel(QEMUBH *bh);
void qemu_bh_delete(QEMUBH *bh);
int qemu_bh_poll(void);
diff --git a/qemu/vl.c b/qemu/vl.c
index 1afe36e..137074b 100644
--- a/qemu/vl.c
+++ a/qemu/vl.c
@@ -7578,6 +7578,8 @@ struct QEMUBH {
QEMUBHFunc *cb;
void *opaque;
int scheduled;
+ int idle;
+ int deleted;
QEMUBH *next;
};
@@ -7591,37 +7593,56 @@ QEMUBH *qemu_bh_new(QEMUBHFunc *cb, void *opaque)
return NULL;
bh->cb = cb;
bh->opaque = opaque;
+ bh->next = first_bh;
+ first_bh = bh;
return bh;
}
int qemu_bh_poll(void)
{
- QEMUBH *bh, **pbh;
+ QEMUBH *bh, **bhp;
int ret;
ret = 0;
- for(;;) {
- pbh = &first_bh;
- bh = *pbh;
- if (!bh)
- break;
- ret = 1;
- *pbh = bh->next;
- bh->scheduled = 0;
- bh->cb(bh->opaque);
+ for (bh = first_bh; bh; bh = bh->next) {
+ if (!bh->deleted && bh->scheduled) {
+ bh->scheduled = 0;
+ if (!bh->idle)
+ ret = 1;
+ bh->idle = 0;
+ bh->cb(bh->opaque);
+ }
}
+
+ /* remove deleted bhs */
+ bhp = &first_bh;
+ while (*bhp) {
+ bh = *bhp;
+ if (bh->deleted) {
+ *bhp = bh->next;
+ qemu_free(bh);
+ } else
+ bhp = &bh->next;
+ }
+
return ret;
}
+void qemu_bh_schedule_idle(QEMUBH *bh)
+{
+ if (bh->scheduled)
+ return;
+ bh->scheduled = 1;
+ bh->idle = 1;
+}
+
void qemu_bh_schedule(QEMUBH *bh)
{
CPUState *env = cpu_single_env;
if (bh->scheduled)
return;
bh->scheduled = 1;
- bh->next = first_bh;
- first_bh = bh;
-
+ bh->idle = 0;
/* stop the currently executing CPU to execute the BH ASAP */
if (env) {
cpu_interrupt(env, CPU_INTERRUPT_EXIT);
@@ -7630,20 +7651,13 @@ void qemu_bh_schedule(QEMUBH *bh)
void qemu_bh_cancel(QEMUBH *bh)
{
- QEMUBH **pbh;
- if (bh->scheduled) {
- pbh = &first_bh;
- while (*pbh != bh)
- pbh = &(*pbh)->next;
- *pbh = bh->next;
- bh->scheduled = 0;
- }
+ bh->scheduled = 0;
}
void qemu_bh_delete(QEMUBH *bh)
{
- qemu_bh_cancel(bh);
- qemu_free(bh);
+ bh->scheduled = 0;
+ bh->deleted = 1;
}
/***********************************************************/
--
1.5.6
++++++ kvm-pre81-user-0021-fix-bdrv_aio_read-API-breakage-in-qcow2-Andrea-Arca.patch ++++++
>From af1405b9c816541a22719409755c2ed1edb5a8f2 Mon Sep 17 00:00:00 2001
From: aliguori <aliguori>
Date: Fri, 31 Oct 2008 17:28:00 +0000
Subject: [PATCH] fix bdrv_aio_read API breakage in qcow2 (Andrea Arcangeli)
I noticed the qemu_aio_flush was doing nothing at all. And a flood of
cmd_writeb commands leading to a noop-invocation of qemu_aio_flush
were executed.
In short all 'memset;goto redo' places must be fixed to use the bh and
not to call the callback in the context of bdrv_aio_read or the
bdrv_aio_read model falls apart. Reading from qcow2 holes is possible
with phyisical readahead (kind of breada in linux buffer cache).
This is needed at least for scsi, ide is lucky (or it has been
band-aided against this API breakage by fixing the symptom and not the
real bug).
Same bug exists in qcow of course, can be fixed later as it's less
urgent.
Signed-off-by: Andrea Arcangeli <aarcange(a)redhat.com>
Signed-off-by: Anthony Liguori <aliguori(a)us.ibm.com>
---
a/qemu/block-qcow2.c | 44 ++++++++++++++++++++++++++++++++++++++++----
1 files changed, 40 insertions(+), 4 deletions(-)
diff --git a/qemu/block-qcow2.c b/qemu/block-qcow2.c
index 693cd77..dc73769 100644
--- a/qemu/block-qcow2.c
+++ a/qemu/block-qcow2.c
@@ -1165,8 +1165,18 @@ typedef struct QCowAIOCB {
uint64_t cluster_offset;
uint8_t *cluster_data;
BlockDriverAIOCB *hd_aiocb;
+ QEMUBH *bh;
} QCowAIOCB;
+static void qcow_aio_read_cb(void *opaque, int ret);
+static void qcow_aio_read_bh(void *opaque)
+{
+ QCowAIOCB *acb = opaque;
+ qemu_bh_delete(acb->bh);
+ acb->bh = NULL;
+ qcow_aio_read_cb(opaque, 0);
+}
+
static void qcow_aio_read_cb(void *opaque, int ret)
{
QCowAIOCB *acb = opaque;
@@ -1182,7 +1192,6 @@ static void qcow_aio_read_cb(void *opaque, int ret)
return;
}
- redo:
/* post process the read buffer */
if (!acb->cluster_offset) {
/* nothing to do */
@@ -1223,12 +1232,30 @@ static void qcow_aio_read_cb(void *opaque, int ret)
if (acb->hd_aiocb == NULL)
goto fail;
} else {
- goto redo;
+ if (acb->bh) {
+ ret = -EIO;
+ goto fail;
+ }
+ acb->bh = qemu_bh_new(qcow_aio_read_bh, acb);
+ if (!acb->bh) {
+ ret = -EIO;
+ goto fail;
+ }
+ qemu_bh_schedule(acb->bh);
}
} else {
/* Note: in this case, no need to wait */
memset(acb->buf, 0, 512 * acb->n);
- goto redo;
+ if (acb->bh) {
+ ret = -EIO;
+ goto fail;
+ }
+ acb->bh = qemu_bh_new(qcow_aio_read_bh, acb);
+ if (!acb->bh) {
+ ret = -EIO;
+ goto fail;
+ }
+ qemu_bh_schedule(acb->bh);
}
} else if (acb->cluster_offset & QCOW_OFLAG_COMPRESSED) {
/* add AIO support for compressed blocks ? */
@@ -1236,7 +1263,16 @@ static void qcow_aio_read_cb(void *opaque, int ret)
goto fail;
memcpy(acb->buf,
s->cluster_cache + index_in_cluster * 512, 512 * acb->n);
- goto redo;
+ if (acb->bh) {
+ ret = -EIO;
+ goto fail;
+ }
+ acb->bh = qemu_bh_new(qcow_aio_read_bh, acb);
+ if (!acb->bh) {
+ ret = -EIO;
+ goto fail;
+ }
+ qemu_bh_schedule(acb->bh);
} else {
if ((acb->cluster_offset & 511) != 0) {
ret = -EIO;
--
1.5.6
++++++ kvm-pre81-user-0033-CVE-2008-4539-fix-a-heap-overflow-in-Cirrus-emulati.patch ++++++
>From 8af1b920763da9802902603a17da9d5db1307b8d Mon Sep 17 00:00:00 2001
From: aurel32 <aurel32>
Date: Sat, 1 Nov 2008 00:53:39 +0000
Subject: [PATCH] CVE-2008-4539: fix a heap overflow in Cirrus emulation
The code in hw/cirrus_vga.c has changed a lot between CVE-2007-1320 has
been announced and the patch has been applied. As a consequence it has
wrongly applied and QEMU is still vulnerable to this bug if using VNC.
(noticed by Jan Niehusmann)
Signed-off-by: Aurelien Jarno <aurelien(a)aurel32.net>
---
a/qemu/hw/cirrus_vga.c | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/qemu/hw/cirrus_vga.c b/qemu/hw/cirrus_vga.c
index 55f3ced..af9c9e6 100644
--- a/qemu/hw/cirrus_vga.c
+++ a/qemu/hw/cirrus_vga.c
@@ -785,15 +785,14 @@ static void cirrus_do_copy(CirrusVGAState *s, int dst, int src, int w, int h)
static int cirrus_bitblt_videotovideo_copy(CirrusVGAState * s)
{
+ if (BLTUNSAFE(s))
+ return 0;
+
if (s->ds->dpy_copy) {
cirrus_do_copy(s, s->cirrus_blt_dstaddr - s->start_addr,
s->cirrus_blt_srcaddr - s->start_addr,
s->cirrus_blt_width, s->cirrus_blt_height);
} else {
-
- if (BLTUNSAFE(s))
- return 0;
-
(*s->cirrus_rop) (s, s->vram_ptr +
(s->cirrus_blt_dstaddr & s->cirrus_addr_mask),
s->vram_ptr +
--
1.5.6
++++++ kvm-pre81-user-0044-kvm-qemu-increase-size-of-tun-tap-buffer.patch ++++++
>From a08db73bca2bfe05ad446f40af7bea1cdd09d6b1 Mon Sep 17 00:00:00 2001
From: Mark McLoughlin <markmc(a)redhat.com>
Date: Fri, 31 Oct 2008 12:28:45 +0000
Subject: [PATCH] kvm: qemu: increase size of tun/tap buffer
As debugged by Matthew Faulkner, with a 4k byte tap buffer if you
increase the MTU on the tap device to greater than 4k, the packets
read by qemu into the tap buffer will be truncated and the guest
will discard the packet.
With GSO enabled, we use a 64k tap buffer, so let's just use a 64k
buffer in all cases.
Also, remove the obtuse logic for figuring out the max GSO buffer
size. We shouldn't receive IP packets larger than 64k, so let's just
use 17 pages to make sure we've enough room for headers.
Signed-off-by: Mark McLoughlin <markmc(a)redhat.com>
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
a/qemu/vl.c | 14 ++++++--------
1 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/qemu/vl.c b/qemu/vl.c
index 7fce66d..561e254 100644
--- a/qemu/vl.c
+++ a/qemu/vl.c
@@ -4416,15 +4416,13 @@ void tap_using_vnet_hdr(void *opaque, int using_vnet_hdr)
#else /* !defined(_WIN32) */
-#ifndef IFF_VNET_HDR
-#define TAP_BUFSIZE 4096
-#else
+/* Maximum GSO packet size (64k) plus plenty of room for
+ * the ethernet and virtio_net headers
+ */
+#define TAP_BUFSIZE (4096 + 65536)
+
+#ifdef IFF_VNET_HDR
#include <linux/virtio_net.h>
-#define ETH_HLEN 14
-#define ETH_DATA_LEN 1500
-#define MAX_PACKET_LEN (ETH_HLEN + ETH_DATA_LEN)
-#define MAX_SKB_FRAGS ((65536/TARGET_PAGE_SIZE) + 2)
-#define TAP_BUFSIZE (sizeof(struct virtio_net_hdr) + MAX_PACKET_LEN + (MAX_SKB_FRAGS*TARGET_PAGE_SIZE))
#endif
typedef struct TAPState {
--
1.5.6
++++++ kvm-pre81-user-0325-kvm-libkvm-export-KVM_CAP_DESTROY_MEMORY_REGION_WO.patch ++++++
>From 2c6bc0c778daa38fe6c9bb6087434ebd1da3032c Mon Sep 17 00:00:00 2001
From: Avi Kivity <avi(a)redhat.com>
Date: Tue, 9 Dec 2008 14:53:45 +0200
Subject: [PATCH] kvm: libkvm: export KVM_CAP_DESTROY_MEMORY_REGION_WORKS
Signed-off-by: Avi Kivity <avi(a)redhat.com>
---
libkvm/libkvm.c | 13 +++++++++++++
libkvm/libkvm.h | 9 +++++++++
2 files changed, 22 insertions(+), 0 deletions(-)
Index: kvm-78/libkvm/libkvm.c
===================================================================
--- kvm-78.orig/libkvm/libkvm.c
+++ kvm-78/libkvm/libkvm.c
@@ -795,6 +795,19 @@ int kvm_set_mpstate(kvm_context_t kvm, i
}
#endif
+int kvm_destroy_memory_region_works(kvm_context_t kvm)
+{
+ int ret = 0;
+
+#ifdef KVM_CAP_DESTROY_MEMORY_REGION_WORKS
+ ret = ioctl(kvm->fd, KVM_CHECK_EXTENSION,
+ KVM_CAP_DESTROY_MEMORY_REGION_WORKS);
+ if (ret <= 0)
+ ret = 0;
+#endif
+ return ret;
+}
+
static int handle_mmio(kvm_context_t kvm, struct kvm_run *kvm_run)
{
unsigned long addr = kvm_run->mmio.phys_addr;
Index: kvm-78/libkvm/libkvm.h
===================================================================
--- kvm-78.orig/libkvm/libkvm.h
+++ kvm-78/libkvm/libkvm.h
@@ -322,6 +322,15 @@ int kvm_get_sregs(kvm_context_t kvm, int
*/
int kvm_set_sregs(kvm_context_t kvm, int vcpu, struct kvm_sregs *regs);
+
+/*!
+ * \brief Determines whether destroying memory regions is allowed
+ *
+ * KVM before 2.6.29 had a bug when destroying memory regions.
+ *
+ * \param kvm Pointer to the current kvm_context
+ */
+int kvm_destroy_memory_region_works(kvm_context_t kvm);
#ifdef KVM_CAP_MP_STATE
/*!
* * \brief Read VCPU MP state
++++++ kvm-preXX-altgr-and-dead-keys-with-VNC.patch ++++++
From: "Marcel Zumstein" <marcel.zumstein(a)oxinia.ch>
Subject: [Qemu-devel] AltGr and dead keys with VNC
In VNC mode, my AltGr key (mapped to ISO_Level3_Shift) and the dead keys
aren't supported. This patch adds XK_ISO_Level3_Shift (keysym 0xfe03) to
the keymap. Furthermore, it adds support for the dead keys, which were
for some reason present in the keymaps, but not in vnc_keysym.h. This is
relevant for VNC viewers that pass dead keys on to the guest system
(e.g. tightvnc does) and don't compose the accented letters themselves.
Index: qemu/keymaps/modifiers
===================================================================
--- qemu/keymaps/modifiers.orig
+++ qemu/keymaps/modifiers
@@ -3,6 +3,7 @@ Shift_L 0x2a
Alt_R 0xb8
Mode_switch 0xb8
+ISO_Level3_Shift 0xb8
Alt_L 0x38
Control_R 0x9d
Index: qemu/vnc_keysym.h
===================================================================
--- qemu/vnc_keysym.h.orig
+++ qemu/vnc_keysym.h
@@ -204,6 +204,7 @@ static const name2keysym_t name2keysym[]
{"EuroSign", 0x20ac}, /* XK_EuroSign */
/* modifiers */
+{"ISO_Level3_Shift", 0xfe03}, /* XK_ISO_Level3_Shift */
{"Control_L", 0xffe3}, /* XK_Control_L */
{"Control_R", 0xffe4}, /* XK_Control_R */
{"Alt_L", 0xffe9}, /* XK_Alt_L */
@@ -286,6 +287,27 @@ static const name2keysym_t name2keysym[]
{"Pause", 0xff13}, /* XK_Pause */
{"Escape", 0xff1b}, /* XK_Escape */
+/* dead keys */
+{"dead_grave", 0xfe50}, /* XK_dead_grave */
+{"dead_acute", 0xfe51}, /* XK_dead_acute */
+{"dead_circumflex", 0xfe52}, /* XK_dead_circumflex */
+{"dead_tilde", 0xfe53}, /* XK_dead_tilde */
+{"dead_macron", 0xfe54}, /* XK_dead_macron */
+{"dead_breve", 0xfe55}, /* XK_dead_breve */
+{"dead_abovedot", 0xfe56}, /* XK_dead_abovedot */
+{"dead_diaeresis", 0xfe57}, /* XK_dead_diaeresis */
+{"dead_abovering", 0xfe58}, /* XK_dead_abovering */
+{"dead_doubleacute", 0xfe59}, /* XK_dead_doubleacute */
+{"dead_caron", 0xfe5a}, /* XK_dead_caron */
+{"dead_cedilla", 0xfe5b}, /* XK_dead_cedilla */
+{"dead_ogonek", 0xfe5c}, /* XK_dead_ogonek */
+{"dead_iota", 0xfe5d}, /* XK_dead_iota */
+{"dead_voiced_sound", 0xfe5e}, /* XK_dead_voiced_sound */
+{"dead_semivoiced_sound", 0xfe5f}, /* XK_dead_semivoiced_sound */
+{"dead_belowdot", 0xfe60}, /* XK_dead_belowdot */
+{"dead_hook", 0xfe61}, /* XK_dead_hook */
+{"dead_horn", 0xfe62}, /* XK_dead_horn */
+
/* localized keys */
{"BackApostrophe", 0xff21},
{"Muhenkan", 0xff22},
++++++ kvm-qemu-no-fallback-if-open-kvm-fails.patch ++++++
Index: kvm-78/qemu/vl.c
===================================================================
--- kvm-78.orig/qemu/vl.c
+++ kvm-78/qemu/vl.c
@@ -10057,7 +10057,8 @@ int main(int argc, char **argv)
if (kvm_enabled()) {
if (kvm_qemu_init() < 0) {
extern int kvm_allowed;
- fprintf(stderr, "Could not initialize KVM, will disable KVM support\n");
+ fprintf(stderr, "Could not initialize KVM. Do you have kvm-amd or kvm-intel modprobe'd?\nIf you want to use CPU emulation, start with -no-kvm.\n");
+ exit(1);
#ifdef NO_CPU_EMULATION
fprintf(stderr, "Compiled with --disable-cpu-emulation, exiting.\n");
exit(1);
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package brp-check-suse for openSUSE:Factory
checked in at Tue Dec 16 17:42:01 CET 2008.
--------
--- brp-check-suse/brp-check-suse.changes 2008-12-04 14:15:34.000000000 +0100
+++ /mounts/work_src_done/STABLE/brp-check-suse/brp-check-suse.changes 2008-12-16 15:53:19.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Dec 16 15:53:03 CET 2008 - lnussel(a)suse.de
+
+- remove dbus script, replaced by rpmlint check
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ brp-check-suse.spec ++++++
--- /var/tmp/diff_new_pack.L15724/_old 2008-12-16 17:41:49.000000000 +0100
+++ /var/tmp/diff_new_pack.L15724/_new 2008-12-16 17:41:49.000000000 +0100
@@ -24,7 +24,7 @@
AutoReqProv: on
Summary: build root policy check scripts
Version: 1.0
-Release: 15
+Release: 16
Source0: %{name}-%{version}.tar.bz2
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
@@ -56,6 +56,8 @@
/usr/lib/rpm/*
%changelog
+* Tue Dec 16 2008 lnussel(a)suse.de
+- remove dbus script, replaced by rpmlint check
* Thu Dec 04 2008 thomas(a)suse.de
- updated dbus whitelist for package sugar
* Thu Nov 20 2008 thomas(a)suse.de
++++++ brp-check-suse-1.0.tar.bz2 ++++++
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/brp-check-suse-1.0/brp-dbus-autostart new/brp-check-suse-1.0/brp-dbus-autostart
--- old/brp-check-suse-1.0/brp-dbus-autostart 2008-11-20 15:28:11.000000000 +0100
+++ new/brp-check-suse-1.0/brp-dbus-autostart 1970-01-01 01:00:00.000000000 +0100
@@ -1,53 +0,0 @@
-#!/bin/sh
-# author: Thomas Biege <thomas(a)suse.de>
-# last update: 2008-09-22
-#
-# purpose: detect packages that want to install an unknown dbus
-# autostart service
-# note: edit macros.brp to include this script
-# see: http://techbase.kde.org/Development/Tutorials/D-Bus/Autostart_Services
-
-if [ -f /usr/lib/rpm/brp-dbus-autostart.data/whitelist ]
-then
- WHITELIST=$(cat /usr/lib/rpm/brp-dbus-autostart.data/whitelist)
-else
- echo "Warning: dbus autostart/system services whitelist file is missing."
- exit 0
-fi
-
-# if using normal root, avoid changing anything.
-if [ -z "$RPM_BUILD_ROOT" -o "$RPM_BUILD_ROOT" = "/" ]; then
- exit 0
-fi
-
-E=$(ls -1 $RPM_BUILD_ROOT/usr/share/dbus-*/system-services/*.service $RPM_BUILD_ROOT/etc/dbus-*/system.d/*.conf 2>/dev/null)
-if ! [ -z "$E" ]
-then
- if [ -z "$WHITELIST" ] # we do not have a whitelist
- then
- echo "Warning: This package installs an unknown D-BUS autostart/system service. Please contact security-team(a)suse.de"
- exit 1 # do stop build process
- fi
-
- for i in $E
- do
- DF=$(basename $i)
-
- FOUND=0
- for j in $WHITELIST
- do
- if [ "$DF" == "$j" ]
- then
- FOUND=1
- fi
- done
- if [ $FOUND -eq 0 ]
- then
- echo "Warning: This package installs an unknown D-BUS autostart/system service. Please contact security-team(a)suse.de: $DF"
- exit 1 # do stop build process
- fi
- done
-fi
-
-exit 0
-
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/brp-check-suse-1.0/brp-dbus-autostart.data/whitelist new/brp-check-suse-1.0/brp-dbus-autostart.data/whitelist
--- old/brp-check-suse-1.0/brp-dbus-autostart.data/whitelist 2008-12-04 14:14:27.000000000 +0100
+++ new/brp-check-suse-1.0/brp-dbus-autostart.data/whitelist 1970-01-01 01:00:00.000000000 +0100
@@ -1,52 +0,0 @@
-avahi-dbus.conf
-backup-manager.conf
-bluetooth.conf
-cnetworkmanager.conf
-com.google.code.BackupManager.service
-com.novell.Pkcs11Monitor.conf
-ConsoleKit.conf
-cups.conf
-fi.epitest.hostap.WPASupplicant.service
-galago-daemon.conf
-gdm.conf
-hal.conf
-kerneloops.dbus
-knetworkmanager.conf
-NetworkManager.conf
-NetworkManagerInfo.conf
-newprinternotification.conf
-nm-applet.conf
-nm-avahi-autoipd.conf
-nm-dhcp-client.conf
-nm-dispatcher.conf
-nm-novellvpn-service.conf
-nm-openvpn-service.conf
-nm-pptp-service.conf
-nm-system-settings.conf
-nm-vpnc-service.conf
-org.bluez.service
-org.freedesktop.ConsoleKit.service
-org.freedesktop.ModemManager.conf
-org.freedesktop.ModemManager.service
-org.freedesktop.NetworkManagerSystemSettings.service
-org.freedesktop.nm_dispatcher.service
-org.freedesktop.PackageKit.conf
-org.freedesktop.PackageKit.service
-org.freedesktop.PolicyKit.conf
-org.freedesktop.PolicyKit.service
-org.gnome.ClockApplet.Mechanism.conf
-org.gnome.ClockApplet.Mechanism.service
-org.gnome.GConf.Defaults.conf
-org.gnome.GConf.Defaults.service
-org.opensuse.BackupManager.service
-org.opensuse.CupsPkHelper.Mechanism.conf
-org.opensuse.CupsPkHelper.Mechanism.service
-org.opensuse.yast.SCR.conf
-org.opensuse.yast.SCR.service
-pommed.conf
-powersave.conf
-system.d
-upsd.conf
-wpa_supplicant.conf
-xorg-server.conf
-yum-updatesd.conf
diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/brp-check-suse-1.0/macros.brp new/brp-check-suse-1.0/macros.brp
--- old/brp-check-suse-1.0/macros.brp 2008-10-16 13:29:23.000000000 +0200
+++ new/brp-check-suse-1.0/macros.brp 2008-12-16 15:52:41.000000000 +0100
@@ -13,6 +13,5 @@
/usr/lib/rpm/brp-check-bytecode-version \
/usr/lib/rpm/brp-boot-scripts \
/usr/lib/rpm/brp-hook \
- /usr/lib/rpm/brp-dbus-autostart \
%{nil}
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package procps for openSUSE:Factory
checked in at Tue Dec 16 16:00:17 CET 2008.
--------
--- procps/procps.changes 2008-12-10 16:31:51.000000000 +0100
+++ /mounts/work_src_done/STABLE/procps/procps.changes 2008-12-15 17:57:25.861891000 +0100
@@ -1,0 +2,5 @@
+Mon Dec 15 17:56:31 CET 2008 - werner(a)suse.de
+
+- Add c option patch to pgrep for counting matches (bnc#459081)
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
procps-3.2.7-pgrep_coption.dif
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ procps.spec ++++++
--- /var/tmp/diff_new_pack.l26442/_old 2008-12-16 16:00:00.000000000 +0100
+++ /var/tmp/diff_new_pack.l26442/_new 2008-12-16 16:00:00.000000000 +0100
@@ -27,7 +27,7 @@
PreReq: %fillup_prereq %insserv_prereq
AutoReqProv: on
Version: 3.2.7
-Release: 148
+Release: 149
Summary: ps utilities for /proc
Provides: ps
Obsoletes: ps
@@ -60,6 +60,7 @@
Patch23: procps-3.2.7-accuracy.dif
Patch24: procps-3.2.7-toosmall.dif
Patch25: procps-3.2.7-cgroups_flag.diff
+Patch26: procps-3.2.7-pgrep_coption.dif
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
@@ -114,6 +115,7 @@
%patch23
%patch24
%patch25 -p1
+%patch26
%build
make CFLAGS="-Wall -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 $RPM_OPT_FLAGS -pipe" \
@@ -179,6 +181,8 @@
%_mandir/man8/sysctl.8.gz
%changelog
+* Mon Dec 15 2008 werner(a)suse.de
+- Add c option patch to pgrep for counting matches (bnc#459081)
* Wed Dec 10 2008 werner(a)suse.de
- Make steal time part in vmstat active (bnc#457383)
- Modify the patch for bnc#435544 to show summary CPU even on
++++++ procps-3.2.7-pgrep_coption.dif ++++++
--- pgrep.1
+++ pgrep.1 2007-10-05 22:36:42.000000000 +1000
@@ -7,7 +7,7 @@
pgrep, pkill \- look up or signal processes based on name and other attributes
.SH SYNOPSIS
-pgrep [\-flvx] [\-d \fIdelimiter\fP] [\-n|\-o] [\-P \fIppid\fP,...] [\-g \fIpgrp\fP,...]
+pgrep [\-cflvx] [\-d \fIdelimiter\fP] [\-n|\-o] [\-P \fIppid\fP,...] [\-g \fIpgrp\fP,...]
.br
[\-s \fIsid\fP,...] [\-u \fIeuid\fP,...] [\-U \fIuid\fP,...] [\-G \fIgid\fP,...]
.br
@@ -38,6 +38,9 @@
.SH OPTIONS
.TP
+\-c
+Suppress normal output; instead print a count of matching processes.
+.TP
\-d \fIdelimiter\fP
Sets the string used to delimit each process ID in the output (by
default a newline). (\fBpgrep\fP only.)
--- pgrep.c
+++ pgrep.c 2007-10-05 22:35:52.000000000 +1000
@@ -54,6 +54,7 @@
static int opt_newest = 0;
static int opt_negate = 0;
static int opt_exact = 0;
+static int opt_count = 0;
static int opt_signal = SIGTERM;
static int opt_lock = 0;
static int opt_case = 0;
@@ -77,7 +78,7 @@
if (i_am_pkill)
fprintf (stderr, "Usage: pkill [-SIGNAL] [-fvx] ");
else
- fprintf (stderr, "Usage: pgrep [-flvx] [-d DELIM] ");
+ fprintf (stderr, "Usage: pgrep [-cflvx] [-d DELIM] ");
fprintf (stderr, "[-n|-o] [-P PPIDLIST] [-g PGRPLIST] [-s SIDLIST]\n"
"\t[-u EUIDLIST] [-U UIDLIST] [-G GIDLIST] [-t TERMLIST] "
"[PATTERN]\n");
@@ -562,7 +563,7 @@
strcat (opts, "ld:");
}
- strcat (opts, "LF:fnovxP:g:s:u:U:G:t:?V");
+ strcat (opts, "LF:cfnovxP:g:s:u:U:G:t:?V");
while ((opt = getopt (argc, argv, opts)) != -1) {
switch (opt) {
@@ -610,6 +611,9 @@
exit(EXIT_SUCCESS);
// case 'c': // Solaris: match by contract ID
// break;
+ case 'c':
+ opt_count = 1;
+ break;
case 'd': // Solaris: change the delimiter
opt_delim = strdup (optarg);
break;
@@ -721,10 +725,14 @@
procs[i].num, strerror (errno));
}
} else {
- if (opt_long)
- output_strlist(procs,num);
- else
- output_numlist(procs,num);
+ if (opt_count) {
+ fprintf(stdout, "%ld\n", num);
+ } else {
+ if (opt_long)
+ output_strlist (procs,num);
+ else
+ output_numlist (procs,num);
+ }
}
return !num; // exit(EXIT_SUCCESS) if match, otherwise exit(EXIT_FAILURE)
}
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package nspluginwrapper for openSUSE:Factory
checked in at Tue Dec 16 16:00:04 CET 2008.
--------
--- nspluginwrapper/nspluginwrapper.changes 2008-12-12 16:41:59.000000000 +0100
+++ /mounts/work_src_done/STABLE/nspluginwrapper/nspluginwrapper.changes 2008-12-15 15:14:58.000000000 +0100
@@ -1,0 +2,6 @@
+Mon Dec 15 15:11:06 CET 2008 - sbrabec(a)suse.cz
+
+- Correct fixes for ordered comparisons of pointer with zero
+ (bnc#432616#c2).
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
nspluginwrapper-fix-plugin-info-parser.patch
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ nspluginwrapper.spec ++++++
--- /var/tmp/diff_new_pack.j20728/_old 2008-12-16 15:55:33.000000000 +0100
+++ /var/tmp/diff_new_pack.j20728/_new 2008-12-16 15:55:33.000000000 +0100
@@ -20,7 +20,7 @@
Name: nspluginwrapper
Version: 1.1.10
-Release: 1
+Release: 2
Group: Productivity/Networking/Web/Utilities
Summary: Compatibility Layer for Netscape 4 Plug-Ins
License: GPL v2 or later
@@ -30,6 +30,7 @@
# (Now it's done differently, but still only a work-around.)
Patch: nspluginwrapper-silence.patch
Patch1: nspluginwrapper-comparison.patch
+Patch2: nspluginwrapper-fix-plugin-info-parser.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: curl-devel glib2-devel gtk2-devel
BuildRequires: gcc-c++
@@ -66,6 +67,7 @@
%setup -q
#%patch
%patch1
+%patch2
%build
#
@@ -130,6 +132,9 @@
%{_prefix}/lib/%{name}
%changelog
+* Mon Dec 15 2008 sbrabec(a)suse.cz
+- Correct fixes for ordered comparisons of pointer with zero
+ (bnc#432616#c2).
* Fri Dec 12 2008 sbrabec(a)suse.cz
- Updated to version 1.1.10 (bnc#447434):
* Fix XEMBED (rework for lost events/focus regressions,
++++++ nspluginwrapper-comparison.patch ++++++
--- /var/tmp/diff_new_pack.j20728/_old 2008-12-16 15:55:33.000000000 +0100
+++ /var/tmp/diff_new_pack.j20728/_new 2008-12-16 15:55:33.000000000 +0100
@@ -6,7 +6,7 @@
void npobject_associate(NPObject *npobj, NPObjectInfo *npobj_info)
{
- assert(npobj && npobj_info && npobj_info > 0);
-+ assert(npobj && npobj_info);
++ assert(npobj && npobj_info && npobj_info->npobj_id > 0);
npobject_hash_table_insert(npobj, npobj_info);
}
++++++ nspluginwrapper-fix-plugin-info-parser.patch ++++++
Index: src/npw-wrapper.c
===================================================================
--- src/npw-wrapper.c (revision 820)
+++ src/npw-wrapper.c (revision 821)
@@ -3371,7 +3371,7 @@
// Consume the whole line, we can't see our tags here
while (fgets(line, sizeof(line), viewer_fp)) {
len = strlen(line);
- if (line > 0 && line[len - 1] == '\n')
+ if (len > 0 && line[len - 1] == '\n')
break;
}
continue;
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package man-pages for openSUSE:Factory
checked in at Tue Dec 16 15:54:34 CET 2008.
--------
--- man-pages/man-pages.changes 2008-11-24 14:41:03.000000000 +0100
+++ /mounts/work_src_done/STABLE/man-pages/man-pages.changes 2008-12-15 15:47:42.000000000 +0100
@@ -1,0 +2,5 @@
+Mon Dec 15 15:47:01 CET 2008 - pgajdos(a)suse.cz
+
+- updated to 3.15, fixes [bnc#441558]
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
man-pages-3.13.tar.bz2
New:
----
man-pages-3.15.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ man-pages.spec ++++++
--- /var/tmp/diff_new_pack.F16710/_old 2008-12-16 15:54:05.000000000 +0100
+++ /var/tmp/diff_new_pack.F16710/_new 2008-12-16 15:54:05.000000000 +0100
@@ -1,5 +1,5 @@
#
-# spec file for package man-pages (Version 3.13)
+# spec file for package man-pages (Version 3.15)
#
# Copyright (c) 2008 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -24,8 +24,8 @@
License: BSD 3-Clause; GPL v2 or later; Other uncritical OpenSource License
Group: Documentation/Man
AutoReqProv: on
-Version: 3.13
-Release: 2
+Version: 3.15
+Release: 1
Summary: Linux Manual Pages
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Source: man-pages-%{version}.tar.bz2
@@ -111,6 +111,8 @@
%doc Changes
%changelog
+* Mon Dec 15 2008 pgajdos(a)suse.cz
+- updated to 3.15, fixes [bnc#441558]
* Mon Nov 24 2008 pgajdos(a)suse.cz
- removed host.conf.patch, command mdns on/off no longer available
[bnc#446017]
++++++ man-pages-3.13.tar.bz2 -> man-pages-3.15.tar.bz2 ++++++
++++ 22677 lines of diff (skipped)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package libkdcraw3 for openSUSE:Factory
checked in at Tue Dec 16 15:53:56 CET 2008.
--------
--- KDE/libkdcraw3/libkdcraw3.changes 2008-11-05 13:24:01.000000000 +0100
+++ /mounts/work_src_done/STABLE/libkdcraw3/libkdcraw3.changes 2008-12-16 14:23:49.188850000 +0100
@@ -1,0 +2,5 @@
+Tue Dec 16 14:23:44 CET 2008 - coolo(a)suse.de
+
+- require lang subpackage
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ libkdcraw3.spec ++++++
--- /var/tmp/diff_new_pack.g12670/_old 2008-12-16 15:50:49.000000000 +0100
+++ /var/tmp/diff_new_pack.g12670/_new 2008-12-16 15:50:49.000000000 +0100
@@ -25,9 +25,10 @@
Group: Development/Libraries/KDE
Summary: Shared library interface around dcraw
Version: 0.1.4
-Release: 49
+Release: 50
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Source0: libkdcraw-%{version}.tar.bz2
+Requires: %{name}-lang = %{version}
%description
Libkdcraw is a C++ interface around dcraw binary program used to decode
@@ -112,6 +113,8 @@
/opt/kde3/share/icons/hicolor/*x*/apps/kdcraw.png
%changelog
+* Tue Dec 16 2008 coolo(a)suse.de
+- require lang subpackage
* Wed Nov 05 2008 dmueller(a)suse.de
- rename libkdcraw-devel to libkdcraw3-devel
* Tue May 06 2008 dmueller(a)suse.de
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package kdeutils4 for openSUSE:Factory
checked in at Tue Dec 16 15:50:37 CET 2008.
--------
--- KDE/kdeutils4/kdeutils4.changes 2008-11-20 18:30:48.000000000 +0100
+++ /mounts/work_src_done/STABLE/kdeutils4/kdeutils4.changes 2008-12-16 13:39:12.000000000 +0100
@@ -1,0 +2,5 @@
+Tue Dec 16 13:38:50 CET 2008 - stbinner(a)suse.de
+
+- versionized split-provides are not supported
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ kdeutils4.spec ++++++
--- /var/tmp/diff_new_pack.z10056/_old 2008-12-16 15:50:26.000000000 +0100
+++ /var/tmp/diff_new_pack.z10056/_new 2008-12-16 15:50:26.000000000 +0100
@@ -29,7 +29,7 @@
Summary: Base Package of KDE Utility Programs
Url: http://www.kde.org
Version: 4.1.3
-Release: 2
+Release: 3
Source0: kdeutils-%version.tar.bz2
Source1: _upstream
Patch: 4_1_BRANCH.diff
@@ -149,7 +149,7 @@
Group: Productivity/Scientific/Math
Summary: Scientific Calculator
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kcalc = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kcalc
%description -n kde4-kcalc
KCalc is the KDE calculator tool.
@@ -196,7 +196,7 @@
Group: System/GUI/KDE
Summary: Remote Application Executor
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kdessh = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kdessh
%description -n kde4-kdessh
Runs a program on a remote host
@@ -220,7 +220,7 @@
Group: System/Monitoring
Summary: Disk Usage Viewer
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kdf = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kdf
%description -n kde4-kdf
KDE free disk space utility
@@ -247,7 +247,7 @@
Group: System/GUI/KDE
Summary: Floppy Formatter
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kfloppy = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kfloppy
%description -n kde4-kfloppy
KDE Floppy Disk Utility
@@ -271,7 +271,7 @@
Group: Productivity/Security
Summary: Encryption Tool
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kgpg = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kgpg
%description -n kde4-kgpg
Kgpg is a simple GUI for gpg
@@ -318,7 +318,7 @@
Group: System/GUI/KDE
Summary: Wallet Management Tool
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kwalletmanager = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kwalletmanager
%description -n kde4-kwalletmanager
This application allows you to manage your KDE password wallet.
@@ -347,7 +347,7 @@
Group: System/GUI/KDE
Summary: Removable Media Utility
%kde4_runtime_requires
-Provides: kdeutils3:/opt/kde3/bin/kwikdisk = 3.5.1
+Provides: kdeutils3:/opt/kde3/bin/kwikdisk
%description -n kde4-kwikdisk
This utility allows you to manage removable media.
@@ -472,6 +472,8 @@
%doc %lang(en) /usr/share/doc/kde/HTML/en/kcontrol/blockdevices
%changelog
+* Tue Dec 16 2008 stbinner(a)suse.de
+- versionized split-provides are not supported
* Thu Nov 20 2008 stbinner(a)suse.de
- add SLE provides/obsoletes
* Fri Oct 31 2008 dmueller(a)suse.de
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0
Hello community,
here is the log from the commit of package kdepim4 for openSUSE:Factory
checked in at Tue Dec 16 15:50:28 CET 2008.
--------
--- KDE/kdepim4/kdepim4.changes 2008-12-04 10:36:27.000000000 +0100
+++ /mounts/work_src_done/STABLE/kdepim4/kdepim4.changes 2008-12-16 13:40:43.000000000 +0100
@@ -1,0 +2,17 @@
+Tue Dec 16 13:40:31 CET 2008 - stbinner(a)suse.de
+
+- versionized split-provides are not supported
+
+-------------------------------------------------------------------
+Fri Dec 12 08:28:00 CET 2008 - wstephenson(a)suse.de
+
+- Don't install namelink .so's for private shared libs (bnc#420162)
+ Fixes KDE3 kmail startup when kdepim4-devel is installed
+
+-------------------------------------------------------------------
+Thu Dec 5 11:15:00 CET 2008 - wstephenson(a)suse.de
+
+- Fix korganizer/kontact showing UTC datetimes instead of localtime
+ (bnc#441022)
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
New:
----
display-events-in-localtime.diff
dont-install-private-shlib-namelinks.diff
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ kdepim4.spec ++++++
--- /var/tmp/diff_new_pack.EE6512/_old 2008-12-16 15:50:00.000000000 +0100
+++ /var/tmp/diff_new_pack.EE6512/_new 2008-12-16 15:50:00.000000000 +0100
@@ -35,7 +35,7 @@
Summary: Base package of kdepim
Url: http://www.kde.org
Version: 4.1.3
-Release: 4
+Release: 5
Source0: kdepim-%version.tar.bz2
Patch: 4_1_BRANCH.diff
Patch1: akregator-useragent.diff
@@ -44,6 +44,8 @@
Patch6: disable-knut.diff
Patch7: knode-kontact-default.diff
Patch8: akonadi_kresource_warning.diff
+Patch9: display-events-in-localtime.diff
+Patch10: dont-install-private-shlib-namelinks.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%kde4_runtime_requires
Suggests: kde4-ktnef
@@ -89,6 +91,8 @@
%patch6
%patch7
%patch8
+%patch9
+%patch10
%build
%ifarch ppc64
@@ -345,7 +349,7 @@
Requires: libkdepim4 = %version
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/akregator = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/akregator
%description -n kde4-akregator
A KDE Feed Aggregator
@@ -371,7 +375,7 @@
Requires: libkdepim4 = %version
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/kaddressbook = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/kaddressbook
%description -n kde4-kaddressbook
The KDE Address Book
@@ -397,7 +401,7 @@
Requires: libkdepim4 = %version
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/kmail = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/kmail
%description -n kde4-kmail
KMail is the mail client of KDE.
@@ -426,7 +430,7 @@
Requires: libkdepim4 = %version
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/knode = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/knode
%description -n kde4-knode
KNode is a usenet news reader for KDE.
@@ -452,7 +456,7 @@
Requires: libkdepim4 = %version
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/knotes = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/knotes
%description -n kde4-knotes
KNotes is a note taking application for KDE.
@@ -533,7 +537,7 @@
Requires: libkdepim4 = %version
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/korganizer = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/korganizer
%description -n kde4-korganizer
KOrganizer is a calendar application for KDE.
@@ -561,7 +565,7 @@
Summary: Mail Alert
%kde4_runtime_requires
%kde4_pimlibs_requires
-Provides: kdepim3:/opt/kde3/bin/korn = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/korn
%description -n kde4-korn
Korn is a mail checker for KDE.
@@ -636,7 +640,7 @@
Group: System/GUI/KDE
Summary: KDE Personal Information Management Wizards
%kde4_runtime_requires
-Provides: kdepim3:/opt/kde3/bin/egroupwarewizard = 3.5.1
+Provides: kdepim3:/opt/kde3/bin/egroupwarewizard
%description wizards
This package contains wizards to setup groupware accounts in Kontact.
@@ -833,6 +837,14 @@
/usr/share/icons/hicolor/*/apps/office-address-book.*
%changelog
+* Tue Dec 16 2008 stbinner(a)suse.de
+- versionized split-provides are not supported
+* Fri Dec 12 2008 wstephenson(a)suse.de
+- Don't install namelink .so's for private shared libs (bnc#420162)
+ Fixes KDE3 kmail startup when kdepim4-devel is installed
+* Fri Dec 05 2008 wstephenson(a)suse.de
+- Fix korganizer/kontact showing UTC datetimes instead of localtime
+ (bnc#441022)
* Thu Dec 04 2008 wstephenson(a)suse.de
- add warning to the Akonadi kresources (bnc#439412)
* Thu Nov 20 2008 stbinner(a)suse.de
++++++ display-events-in-localtime.diff ++++++
Index: korganizer/views/monthview/monthitem.cpp
===================================================================
--- korganizer/views/monthview/monthitem.cpp (revision 895193)
+++ korganizer/views/monthview/monthitem.cpp (working copy)
@@ -503,22 +503,23 @@
{
QString ret = mIncidence->summary();
if ( !allDay() ) { // Prepend the time str to the text
- QTime time;
+ QString timeStr;
if ( mIsTodo ) {
Todo *todo = static_cast<Todo*>( mIncidence );
- time = todo->dtDue().time();
+ timeStr = todo->dtDueTimeStr( true, KOPrefs::instance()->timeSpec() );
} else {
if ( !end ) {
- time = mIncidence->dtStart().time();
+ timeStr = mIncidence->dtStartTimeStr( true, KOPrefs::instance()->timeSpec() );
} else {
- time = mIncidence->dtEnd().time();
+ Event *event = static_cast<Event*>( mIncidence );
+ timeStr = event->dtEndTimeStr( true, KOPrefs::instance()->timeSpec() );
}
}
- if ( time.isValid() ) {
+ if ( !timeStr.isEmpty() ) {
if ( !end ) {
- ret = KGlobal::locale()->formatTime( time ) + ' ' + ret;
+ ret = timeStr + ' ' + ret;
} else {
- ret = ret + ' ' + KGlobal::locale()->formatTime( time );
+ ret = ret + ' ' + timeStr;
}
}
}
@@ -528,7 +529,8 @@
QString IncidenceMonthItem::toolTipText() const
{
- return IncidenceFormatter::toolTipString( mIncidence );
+ return IncidenceFormatter::toolTipStr(
+ mIncidence, true, KOPrefs::instance()->timeSpec() );
}
QList<QPixmap *> IncidenceMonthItem::icons() const
Index: korganizer/CMakeLists.txt
===================================================================
--- korganizer/CMakeLists.txt (revision 895193)
+++ korganizer/CMakeLists.txt (working copy)
@@ -103,7 +103,7 @@
kde4_add_library(korganizer_eventviewer SHARED ${korganizer_eventviewer_LIB_SRCS})
add_dependencies(korganizer_eventviewer kmail_xml)
-target_link_libraries(korganizer_eventviewer ${KDE4_KPARTS_LIBS} ${KDE4_KCAL_LIBS})
+target_link_libraries(korganizer_eventviewer ${KDE4_KPARTS_LIBS} ${KDE4_KCAL_LIBS} kdepim)
set_target_properties(korganizer_eventviewer PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
install(TARGETS korganizer_eventviewer DESTINATION ${LIB_INSTALL_DIR})
Index: korganizer/koeventviewer.cpp
===================================================================
--- korganizer/koeventviewer.cpp (revision 895193)
+++ korganizer/koeventviewer.cpp (working copy)
@@ -29,6 +29,7 @@
#include "koglobals.h"
#include <libkdepim/kdepimprotocols.h>
+#include <libkdepim/kpimprefs.h>
#include <kcal/incidence.h>
#include <kcal/incidenceformatter.h>
@@ -94,8 +95,8 @@
bool KOEventViewer::appendIncidence( Incidence *incidence )
{
- QString codeForIncidence = IncidenceFormatter::extensiveDisplayString( incidence );
- addText( codeForIncidence );
+ addText( IncidenceFormatter::extensiveDisplayStr(
+ incidence, KPIM::KPimPrefs::timeSpec() ) );
return true;
}
++++++ dont-install-private-shlib-namelinks.diff ++++++
Subject: prevent installation of namelink .so's for 'private' shared libraries, preventing symbol clashes
From: wstephenson(a)suse.de
Bug: bnc#420162
Patch-upstream: r895907
Index: akregator/src/CMakeLists.txt
===================================================================
--- akregator/src/CMakeLists.txt (revision 895985)
+++ akregator/src/CMakeLists.txt (working copy)
@@ -39,7 +39,7 @@
SOVERSION ${GENERIC_LIB_SOVERSION}
${KDE4_DISABLE_PROPERTY_}LINK_INTERFACE_LIBRARIES "khtml;kde3support;solid"
)
-install(TARGETS akregatorprivate DESTINATION ${LIB_INSTALL_DIR})
+install(TARGETS akregatorprivate DESTINATION ${LIB_INSTALL_DIR} LIBRARY NAMELINK_SKIP)
########### next target ###############
Index: kmail/CMakeLists.txt
===================================================================
--- kmail/CMakeLists.txt (revision 895985)
+++ kmail/CMakeLists.txt (working copy)
@@ -273,7 +273,7 @@
endif(Nepomuk_FOUND)
set_target_properties(kmailprivate PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
-install(TARGETS kmailprivate DESTINATION ${LIB_INSTALL_DIR})
+install(TARGETS kmailprivate DESTINATION ${LIB_INSTALL_DIR} LIBRARY NAMELINK_SKIP)
########### next target ###############
Index: kaddressbook/CMakeLists.txt
===================================================================
--- kaddressbook/CMakeLists.txt (revision 895985)
+++ kaddressbook/CMakeLists.txt (working copy)
@@ -153,7 +153,7 @@
kdepim4_link_unique_libraries(kaddressbookprivate ${KDE4_SYNDICATION_LIBS} kdepim ${KDE4_KCAL_LIBS} kabc_file_core ${KDE4_KIO_LIBS} ${KDE4_KUTILS_LIBS} ${KDE4_PHONON_LIBS} kabinterfaces kabcommon ${QT_QT3SUPPORT_LIBRARY} kimproxy)
set_target_properties(kaddressbookprivate PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
-install(TARGETS kaddressbookprivate DESTINATION ${LIB_INSTALL_DIR})
+install(TARGETS kaddressbookprivate DESTINATION ${LIB_INSTALL_DIR} LIBRARY NAMELINK_SKIP)
########### install files ###############
Index: kitchensync/src/CMakeLists.txt
===================================================================
--- kitchensync/src/CMakeLists.txt (revision 895985)
+++ kitchensync/src/CMakeLists.txt (working copy)
@@ -74,7 +74,7 @@
kabc kcal kdepim qopensync )
SET_TARGET_PROPERTIES(kitchensyncprivate PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
-INSTALL(TARGETS kitchensyncprivate DESTINATION ${LIB_INSTALL_DIR} )
+INSTALL(TARGETS kitchensyncprivate DESTINATION ${LIB_INSTALL_DIR} LIBRARY NAMELINK_SKIP)
########### next target ###############
Index: kontact/src/CMakeLists.txt
===================================================================
--- kontact/src/CMakeLists.txt (revision 895985)
+++ kontact/src/CMakeLists.txt (working copy)
@@ -20,7 +20,7 @@
kdepim4_link_unique_libraries(kontactprivate ${KDE4_KPARTS_LIBS} kdepim kontactinterfaces ${KDE4_KUTILS_LIBRARY} ${KDE4_KHTML_LIBRARY} ${KDE4_KPIMUTILS_LIBS} )
set_target_properties(kontactprivate PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
-install(TARGETS kontactprivate DESTINATION ${LIB_INSTALL_DIR})
+install(TARGETS kontactprivate DESTINATION ${LIB_INSTALL_DIR} LIBRARY NAMELINK_SKIP)
########### next target ###############
Index: korganizer/CMakeLists.txt
===================================================================
--- korganizer/CMakeLists.txt (revision 895985)
+++ korganizer/CMakeLists.txt (working copy)
@@ -237,7 +237,7 @@
set_target_properties(korganizerprivate PROPERTIES VERSION ${GENERIC_LIB_VERSION} SOVERSION ${GENERIC_LIB_SOVERSION} )
-install(TARGETS korganizerprivate DESTINATION ${LIB_INSTALL_DIR})
+install(TARGETS korganizerprivate DESTINATION ${LIB_INSTALL_DIR} LIBRARY NAMELINK_SKIP)
########### install files ###############
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe(a)opensuse.org
For additional commands, e-mail: opensuse-commit+help(a)opensuse.org
1
0