From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26427 invoked by alias); 22 Jun 2004 11:30:30 -0000 Mailing-List: contact libc-hacker-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-hacker-owner@sources.redhat.com Received: (qmail 26395 invoked from network); 22 Jun 2004 11:30:28 -0000 Received: from unknown (HELO sunsite.ms.mff.cuni.cz) (195.113.15.26) by sourceware.org with SMTP; 22 Jun 2004 11:30:28 -0000 Received: from sunsite.ms.mff.cuni.cz (sunsite.mff.cuni.cz [127.0.0.1]) by sunsite.ms.mff.cuni.cz (8.12.8/8.12.8) with ESMTP id i5M9Fo3j027856; Tue, 22 Jun 2004 11:15:50 +0200 Received: (from jakub@localhost) by sunsite.ms.mff.cuni.cz (8.12.8/8.12.8/Submit) id i5M9Fnlm027849; Tue, 22 Jun 2004 11:15:49 +0200 Date: Tue, 22 Jun 2004 11:30:00 -0000 From: Jakub Jelinek To: Ulrich Drepper , Martin Schwidefsky Cc: Glibc hackers Subject: [PATCH] Fix pthread_cond_broadcast on s390/s390x Message-ID: <20040622091549.GJ5191@sunsite.ms.mff.cuni.cz> Reply-To: Jakub Jelinek Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i X-SW-Source: 2004-06/txt/msg00040.txt.bz2 Hi! This pasto caused in the better case most of FUTEX_CMP_REQUEUE calls return -EAGAIN, but if unlucky it might even succeed when it was supposed to fail. Tested on both s390 and s390x. 2004-06-22 Jakub Jelinek * sysdeps/unix/sysv/linux/s390/lowlevellock.h (lll_futex_requeue): Set __r7 to val, not mutex. --- libc/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h.jj 2004-06-11 14:45:53.000000000 +0200 +++ libc/nptl/sysdeps/unix/sysv/linux/s390/lowlevellock.h 2004-06-22 13:26:54.911154237 +0200 @@ -91,7 +91,7 @@ register unsigned long int __r4 asm ("4") = (long int) (nr_wake); \ register unsigned long int __r5 asm ("5") = (long int) (nr_move); \ register unsigned long int __r6 asm ("6") = (unsigned long int) (mutex); \ - register unsigned long int __r7 asm ("7") = (int) (mutex); \ + register unsigned long int __r7 asm ("7") = (int) (val); \ register unsigned long __result asm ("2"); \ \ __asm __volatile ("svc %b1" \ Jakub