Seen in RH 2.6.32, please consider for longterm 2.6.32 and 2.6.33.
Applies fine to latest 2.6.32 Debian.

RH patch desc:
When a terminal connection to the z/VM IUCV HVC device driver
is established with iucvconn, the session hangs immediately.
If the getty process running on the hvc terminal is killed,
iucvconn might report the following message:
"iucvterm: The version of the received data message is not supported".

Thank you.

----- Forwarded message from Linux Kernel Mailing List 
<[email protected]> -----

Date: Mon, 8 Mar 2010 20:59:02 GMT
From: Linux Kernel Mailing List <[email protected]>
To: [email protected]
Subject: [S390] hvc_iucv: allocate memory buffers for IUCV in zone DMA

Gitweb:     http://git.kernel.org/linus/91a970d9889c7d6f451ee91ed361d0f0119d3778
Commit:     91a970d9889c7d6f451ee91ed361d0f0119d3778
Parent:     596a95cdf0ba35ea353fb5b65750f596d712041e
Author:     Hendrik Brueckner <[email protected]>
AuthorDate: Mon Mar 8 12:25:15 2010 +0100
Committer:  Martin Schwidefsky <[email protected]>
CommitDate: Mon Mar 8 12:25:29 2010 +0100

    [S390] hvc_iucv: allocate memory buffers for IUCV in zone DMA
    
    The device driver must allocate memory for IUCV buffers with GFP_DMA,
    because IUCV cannot address memory above 2GB (31bit addresses only).
    
    Because the IUCV ignores the higher bits of the address, sending and
    receiving IUCV data with this driver might cause memory corruptions.
    
    Signed-off-by: Hendrik Brueckner <[email protected]>
    Signed-off-by: Martin Schwidefsky <[email protected]>
---
 drivers/char/hvc_iucv.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/drivers/char/hvc_iucv.c b/drivers/char/hvc_iucv.c
index 21681a8..37b0542 100644
--- a/drivers/char/hvc_iucv.c
+++ b/drivers/char/hvc_iucv.c
@@ -139,6 +139,8 @@ struct hvc_iucv_private *hvc_iucv_get_private(uint32_t num)
  *
  * This function allocates a new struct iucv_tty_buffer element and, 
optionally,
  * allocates an internal data buffer with the specified size @size.
+ * The internal data buffer is always allocated with GFP_DMA which is
+ * required for receiving and sending data with IUCV.
  * Note: The total message size arises from the internal buffer size and the
  *      members of the iucv_tty_msg structure.
  * The function returns NULL if memory allocation has failed.
@@ -154,7 +156,7 @@ static struct iucv_tty_buffer *alloc_tty_buffer(size_t 
size, gfp_t flags)
 
        if (size > 0) {
                bufp->msg.length = MSG_SIZE(size);
-               bufp->mbuf = kmalloc(bufp->msg.length, flags);
+               bufp->mbuf = kmalloc(bufp->msg.length, flags | GFP_DMA);
                if (!bufp->mbuf) {
                        mempool_free(bufp, hvc_iucv_mempool);
                        return NULL;
@@ -237,7 +239,7 @@ static int hvc_iucv_write(struct hvc_iucv_private *priv,
        if (!rb->mbuf) { /* message not yet received ... */
                /* allocate mem to store msg data; if no memory is available
                 * then leave the buffer on the list and re-try later */
-               rb->mbuf = kmalloc(rb->msg.length, GFP_ATOMIC);
+               rb->mbuf = kmalloc(rb->msg.length, GFP_ATOMIC | GFP_DMA);
                if (!rb->mbuf)
                        return -ENOMEM;
 
--
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

----- End forwarded message -----

_______________________________________________
stable mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/stable

Reply via email to