27 Jan, 2007
7 commits
-
This patch implements forwarding of SHUTDOWN intercepts from the guest on to
userspace on AMD SVM. A SHUTDOWN event occurs when the guest produces a
triple fault (e.g. on reboot). This also fixes the bug that a guest reboot
actually causes a host reboot under some circumstances.Signed-off-by: Joerg Roedel
Signed-off-by: Avi Kivity
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
With the recent guest page fault change, we perform access checks on our
own instead of relying on the cpu. This means we have to perform the nx
checks as well.Software like the google toolbar on windows appears to rely on this
somehow.Signed-off-by: Avi Kivity
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
Check pte permission bits in walk_addr(), instead of scattering the checks all
over the code. This has the following benefits:1. We no longer set the accessed bit for accessed which fail permission checks.
2. Setting the accessed bit is simplified.
3. Under some circumstances, we used to pretend a page fault was fixed when
it would actually fail the access checks. This caused an unnecessary
vmexit.
4. The error code for guest page faults is now correct.The fix helps netbsd further along booting, and allows kvm to pass the new mmu
testsuite.Signed-off-by: Avi Kivity
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
This allows netbsd 3.1 i386 to get further along installing.
Signed-off-by: Avi Kivity
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
There's an obvious typo in svm_{get,set}_idt, causing it to access the ldt
instead.Because these functions are only called for save/load on AMD, the bug does not
impact normal operation. With the fix, save/load works as expected on AMD
hosts.Signed-off-by: Uri Lublin
Signed-off-by: Avi Kivity
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds -
In __writeback_single_inode(), when we find a locked inode and we're not
doing a data-integrity sync, we used to just skip writing entirely,
since we didn't want to wait for the inode to unlock.However, there's really no reason to skip writing the data pages, which
are likely to be the the bulk of the dirty state anyway (and the main
reason why writeback was started for the non-data-integrity case, of
course!)Acked-by: Nick Piggin
Cc: Andrew Morton ,
Cc: Peter Zijlstra
Cc: Hugh Dickins
Cc: David Howells
Signed-off-by: Linus Torvalds -
It's not pretty, but it appears that ext3 with data=journal will clean
pages without ever actually telling the VM that they are clean. This,
in turn, will result in the VM (and balance_dirty_pages() in particular)
to never realize that the pages got cleaned, and wait forever for an
event that already happened.Technically, this seems to be a problem with ext3 itself, but it used to
be hidden by 'try_to_free_buffers()' noticing this situation on its own,
and just working around the filesystem problem.This commit re-instates that hack, in order to avoid a regression for
the 2.6.20 release. This fixes bugzilla 7844:http://bugzilla.kernel.org/show_bug.cgi?id=7844
Peter Zijlstra points out that we should probably retain the debugging
code that this removes from cancel_dirty_page(), and I agree, but for
the imminent release we might as well just silence the warning too
(since it's not a new bug: anything that triggers that warning has been
around forever).Acked-by: Randy Dunlap
Acked-by: Jens Axboe
Acked-by: Peter Zijlstra
Cc: Andrew Morton
Signed-off-by: Linus Torvalds
26 Jan, 2007
1 commit
-
On x86-64, a put_user call using a 64-bit pointer and a constant value that
is > 0xffffffff will produce code that doesn't assemble. This patch fixes
the asm construct to use the Z constraint for 32-bit constants.Signed-off-by: Roland McGrath
Signed-off-by: Linus Torvalds
25 Jan, 2007
13 commits
-
* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
[MIPS] Fix wrong checksum calculation on 64-bit MIPS
[MIPS] VPE loader: Initialize lists before they're actually being used ...
[MIPS] Fix reported amount of freed memory - it's in kB not bytes
[MIPS] vr41xx: need one more nop with mtc0_tlbw_hazard()
[MIPS] SMTC: Fix module build by exporting symbol
[MIPS] SMTC: Fix TLB sizing bug for TLB of 64 >= entries
[MIPS] Fix APM build
[MIPS] There is no __GNUC_MAJOR__ -
Prevent the call to invalidate_inode_pages2() from racing with file writes
by taking the inode->i_mutex across the page cache flush and invalidate.Signed-off-by: Trond Myklebust
Signed-off-by: Linus Torvalds -
Fix the Oops in http://bugzilla.linux-nfs.org/show_bug.cgi?id=138
We shouldn't be calling rpc_release_task() for tasks that are not active.Signed-off-by: Trond Myklebust
Signed-off-by: Linus Torvalds -
The commit 8e3d8433d8c22ca6c42cba4a67d300c39aae7822 ([NET]: MIPS
checksum annotations and cleanups) broke 64-bit MIPS.The problem is the commit replaces some unsigned long with __be32. On
64bit MIPS, a __be32 (i.e. unsigned int) value is represented as a
sign-extented 32-bit value in a 64-bit argument register. So the
address 192.168.0.1 (0xc0a80001) is passed as 0xffffffffc0a80001 to
csum_tcpudp_nofold() but the asm code in the function expects
0x00000000c0a80001, therefore it returns a wrong checksum. Explicit
cast to unsigned long is needed to drop high 32bit.Signed-off-by: Atsushi Nemoto
Signed-off-by: Ralf Baechle -
kspd which due to makefile order happens to be initialized before the
vpe loader causes references to vpecontrol lists before they're actually
been initialized.Signed-off-by: Ralf Baechle
-
While at it, change message on DEC for consistency.
Signed-off-by: Thiemo Seufer
Signed-off-by: Ralf Baechle -
NEC VR4111 and VR4121 need one more nop with mtc0_tlbw_hazard().
Signed-off-by: Yoichi Yuasa
Signed-off-by: Ralf Baechle -
Signed-off-by: Ralf Baechle
-
Signed-off-by: Ralf Baechle
-
Definitions for TIF_FREEZE and _TIF_FREEZE were missing.
Signed-off-by: Ralf Baechle
-
Gcc major version number is in __GNUC__. As side effect fix checking
with sparse if sparse was built with gcc 4.1 and mips cross-compiler
is 3.4.Sparse will inherit version 4.1, __GNUC__ won't be filtered from
"-dM -E -xc" output, sparse will pick only new major, effectively becoming
gcc version 3.1 which is unsupported.Signed-off-by: Alexey Dobriyan
Signed-off-by: Ralf Baechle -
* git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
[CIFS] Fix oops when Windows server sent bad domain name null terminator
[CIFS] cifs sprintf fix
[CIFS] Remove 2 unneeded kzalloc casts
[CIFS] Update CIFS version number
24 Jan, 2007
19 commits
-
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: (23 commits)
[SCTP]: Fix compiler warning.
[IP] TUNNEL: Fix to be built with user application.
[IPV6]: Fixed the size of the netlink message notified by inet6_rt_notify().
[TCP]: rare bad TCP checksum with 2.6.19
[NET]: Process include/linux/if_{addr,link}.h with unifdef
[NETFILTER]: Fix iptables ABI breakage on (at least) CRIS
[IRDA] vlsi_ir.{h,c}: remove kernel 2.4 code
[TCP]: skb is unexpectedly freed.
[IPSEC]: Policy list disorder
[IrDA]: Removed incorrect IRDA_ASSERT()
[IrDA]: irda-usb TX path optimization (was Re: IrDA spams logfiles - since 2.6.19)
[X.25]: Add missing sock_put in x25_receive_data
[SCTP]: Fix SACK sequence during shutdown
[SCTP]: Correctly handle unexpected INIT-ACK chunk.
[SCTP]: Verify some mandatory parameters.
[SCTP]: Set correct error cause value for missing parameters
[NETFILTER]: fix xt_state compile failure
[NETFILTER]: ctnetlink: fix leak in ctnetlink_create_conntrack error path
[SELINUX]: increment flow cache genid
[IPV6] MCAST: Fix joining all-node multicast group on device initialization.
... -
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6:
mv643xx_eth: Fix race condition in mv643xx_eth_free_tx_descs
s2io bogus memset -
Initialize qc->pad_len for each new command. This ensures
that pad_len is not set to a stale value for zero data
length commands.Signed-off-by: Brian King
Signed-off-by: Jeff Garzik -
Fixup the inialization of qc->n_elem. It currently gets
initialized to 1 for commands that do not transfer any data.
Fix this by initializing n_elem to 0 and only setting to 1
in ata_scsi_qc_new when there is data to transfer. This fixes
some problems seen with SATA devices attached to ipr adapters.Signed-off-by: Brian King
Signed-off-by: Jeff Garzik -
Some ATA/ATAPI devices act weirdly after the link is put into slumber
mode. Some hang completely requiring physical power removal while
others fail to wake up till the link is hardreset a couple of times.The addition of slumber on power down was never driven by real need.
It just followed what ahci spec said literally. The spec itself seems
faulty in that it doesn't consider devices (not controllers) which
don't support link powersaving mode.Theory never matches reality when it comes to dark allys of cheap
ATA/ATAPI world. It's just unrealistic to expect vendors to test
rarely used link powersaving feature rigorously. This patch makes
ahci more friendly to the coldness of reality.This shouldn't have any negative effect - when suspend operation
succeeds, we power off the whole machine; otherwise, we wake up
everything. I can't see any reason to be so elaborate with powering
down the link in the first place.Signed-off-by: Tejun Heo
Signed-off-by: Jeff Garzik -
Several people reported issues with certain drive commands timing out on
sata_nv controllers running in ADMA mode. The commands in question were
non-DMA-mapped commands, usually FLUSH CACHE or FLUSH CACHE EXT.From experimentation it appears that the NV_INT_DEV indication isn't
always set when a legitimate command completion interrupt is received on
a legacy-mode command, at least not on these controllers in ADMA mode.
When a command is pending on the port, force the flag on always in the
irq_stat value before calling nv_host_intr so that the drive busy state
is always checked by ata_host_intr.This also fixes some questionable code in nv_host_intr which called
ata_check_status when a command was pending and ata_host_intr returned
"unhandled". If the device interrupted at just the wrong time this could
cause interrupts to be lost.Signed-off-by: Robert Hancock
Signed-off-by: Jeff Garzik -
As with JMicron controllers, ULi M5288 sets interface fatal error bit
on device error including ATAPI CC. This makes libata hardreset the
port on ATAPI CC thus making it impossible to use. Ignore interface
fatal error bit on ULi M5288. This fixes bugzilla bug #7837.Signed-off-by: Tejun Heo
Signed-off-by: Jeff Garzik -
> --- a/net/sctp/sm_statefuns.c
> +++ b/net/sctp/sm_statefuns.c
> @@ -462,24 +461,6 @@ sctp_disposition_t sctp_sf_do_5_1C_ack(const struct sctp_endpoint *ep,> - if (!init_tag) {
> - struct sctp_chunk *reply = sctp_make_abort(asoc, chunk, 0);
> - if (!reply)
> - goto nomem;This introduced a compiler warning, easily fixed.
Signed-off-by: Brian Haley
Signed-off-by: David S. Miller -
include/linux/if_tunnel.h is broken for user application
because it was changed to use __be32 which is required
to include linux/types.h in advance but didn't.(This issue is found when building MIPL2 daemon. We are not sure this
is the last header to be fixed about __be32.)Signed-off-by: Masahide NAKAMURA
Signed-off-by: TAKAMIYA Noriaki
Signed-off-by: David S. Miller -
I think the return value of rt6_nlmsg_size() should includes the
amount of RTA_METRICS.Signed-off-by: Noriaki TAKAMIYA
Acked-by: Thomas Graf
Signed-off-by: David S. Miller -
The patch "Replace CHECKSUM_HW by CHECKSUM_PARTIAL/CHECKSUM_COMPLETE"
changed to unconditional copying of ip_summed field from collapsed
skb. This patch reverts this change.The majority of substantial work including heavy testing
and diagnosing by: Michael Tokarev
Possible reasons pointed by: Herbert Xu and Patrick McHardy.Signed-off-by: Jarek Poplawski
Acked-by: Herbert Xu
Signed-off-by: David S. Miller -
After commit d3dcc077bf88806201093f86325ec656e4dbfbce,
include/linux/if_{addr,link}.h should be processed with unifdef.Signed-off-by: Adrian Bunk
Signed-off-by: David S. Miller -
With the introduction of x_tables we accidentally broke compatibility
by defining IPT_TABLE_MAXNAMELEN to XT_FUNCTION_MAXNAMELEN instead of
XT_TABLE_MAXNAMELEN, which is two bytes larger.On most architectures it doesn't really matter since we don't have
any tables with names that long in the kernel and the structure
layout didn't change because of alignment requirements of following
members. On CRIS however (and other architectures that don't align
data) this changed the structure layout and thus broke compatibility
with old iptables binaries.Changing it back will break compatibility with binaries compiled
against recent kernels again, but since the breakage has only been
there for three releases this seems like the better choice.Spotted by Jonas Berlin .
Signed-off-by: Patrick McHardy
Signed-off-by: David S. Miller -
This patch removes kernel 2.4 compatibility code.
Signed-off-by: Adrian Bunk
Acked-by: Samuel Ortiz
Signed-off-by: David S. Miller -
I encountered a kernel panic with my test program, which is a very
simple IPv6 client-server program.The server side sets IPV6_RECVPKTINFO on a listening socket, and the
client side just sends a message to the server. Then the kernel panic
occurs on the server. (If you need the test program, please let me
know. I can provide it.)This problem happens because a skb is forcibly freed in
tcp_rcv_state_process().When a socket in listening state(TCP_LISTEN) receives a syn packet,
then tcp_v6_conn_request() will be called from
tcp_rcv_state_process(). If the tcp_v6_conn_request() successfully
returns, the skb would be discarded by __kfree_skb().However, in case of a listening socket which was already set
IPV6_RECVPKTINFO, an address of the skb will be stored in
treq->pktopts and a ref count of the skb will be incremented in
tcp_v6_conn_request(). But, even if the skb is still in use, the skb
will be freed. Then someone still using the freed skb will cause the
kernel panic.I suggest to use kfree_skb() instead of __kfree_skb().
Signed-off-by: Masayuki Nakagawa
Signed-off-by: David S. Miller -
The recent hashing introduced an off-by-one bug in policy list insertion.
Instead of adding after the last entry with a lesser or equal priority,
we're adding after the successor of that entry.This patch fixes this and also adds a warning if we detect a duplicate
entry in the policy list. This should never happen due to this if clause.Signed-off-by: Herbert Xu
Signed-off-by: David S. Miller -
With USB2.0 bulk out MTU can be 512 bytes, so checking it only for 64
bytes is incorrect.Signed-off-by: Samuel Ortiz
Signed-off-by: David S. Miller