From patchwork Fri Jul 3 13:38:17 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Liebler X-Patchwork-Id: 491064 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id CFDE9140776 for ; Fri, 3 Jul 2015 23:39:49 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=sourceware.org header.i=@sourceware.org header.b=dnRY8yjf; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; q=dns; s=default; b=KVxxCCsNu/0SMh+AITZKuWUKCvzxlN1 o5J1bJg2JglQu4b4uUI/4HFpGAbHmb8Ba16eithXNBxXi3zDgyQhm+TilMhrAWye b+pBTc+JhUG4FjVS5ZgmB5HrlLQW04MiU7o9oDpGEQ/V+KDxBFDE/jF5m/0Tpcu4 V3MIMeqJYinQ= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id:in-reply-to :references; s=default; bh=tagxCaX1h5bQtLTXOfyaFj951g0=; b=dnRY8 yjfCXILOFTIpf/D1bZx54P5VCkWQoxoXOF9c1IcWXBwT3UwkXgBz2zw5UGxGhZSp dZ8c1s9LmK2Hl38vRPCvCfICSHHwzu5iyJ1HEdCUE/w9MnKwYTq7XWk792yKmrWX W0C+8Q7RnNqbMgkmFWlhwXVixqkCxf2WM4SfOQ= Received: (qmail 95181 invoked by alias); 3 Jul 2015 13:38:56 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 95086 invoked by uid 89); 3 Jul 2015 13:38:55 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.9 required=5.0 tests=AWL, BAYES_00, KAM_LAZY_DOMAIN_SECURITY, RP_MATCHES_RCVD autolearn=no version=3.3.2 X-HELO: e06smtp16.uk.ibm.com X-MailFrom: stli@linux.vnet.ibm.com X-RcptTo: libc-alpha@sourceware.org From: Stefan Liebler To: libc-alpha@sourceware.org Cc: Stefan Liebler Subject: [PATCH 03/27] S390: Add hwcaps value for vector facility. Date: Fri, 3 Jul 2015 15:38:17 +0200 Message-Id: <1435930721-27922-4-git-send-email-stli@linux.vnet.ibm.com> In-Reply-To: <1435930721-27922-1-git-send-email-stli@linux.vnet.ibm.com> References: <1435930721-27922-1-git-send-email-stli@linux.vnet.ibm.com> X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15070313-0025-0000-0000-000005DA4379 The HWCAP_S390_VX flag in hwcap field of auxiliary vector indicates if the vector facility is available and the kernel is aware of it. This can be tested with LD_SHOW_AUXV=1 . Currently it does not show te, because it was not incremented by commit "S/390: Add hwcap value for transactional execution.". Thus _DL_HWCAP_COUNT is incremented by two. ChangeLog: * sysdeps/s390/dl-procinfo.c (_dl_s390_platforms): Add vector flag. * sysdeps/s390/dl-procinfo.h: Add vector capability. * sysdeps/unix/sysv/linux/s390/bits/hwcap.h (HWCAP_S390_VX): Define. --- sysdeps/s390/dl-procinfo.c | 4 ++-- sysdeps/s390/dl-procinfo.h | 3 ++- sysdeps/unix/sysv/linux/s390/bits/hwcap.h | 1 + 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/sysdeps/s390/dl-procinfo.c b/sysdeps/s390/dl-procinfo.c index 96106f1..0f57f03 100644 --- a/sysdeps/s390/dl-procinfo.c +++ b/sysdeps/s390/dl-procinfo.c @@ -46,11 +46,11 @@ #if !defined PROCINFO_DECL && defined SHARED ._dl_s390_cap_flags #else -PROCINFO_CLASS const char _dl_s390_cap_flags[11][9] +PROCINFO_CLASS const char _dl_s390_cap_flags[12][9] #endif #ifndef PROCINFO_DECL = { - "esan3", "zarch", "stfle", "msa", "ldisp", "eimm", "dfp", "edat", "etf3eh", "highgprs", "te" + "esan3", "zarch", "stfle", "msa", "ldisp", "eimm", "dfp", "edat", "etf3eh", "highgprs", "te", "vx" } #endif #if !defined SHARED || defined PROCINFO_DECL diff --git a/sysdeps/s390/dl-procinfo.h b/sysdeps/s390/dl-procinfo.h index 0f728ab..151b891 100644 --- a/sysdeps/s390/dl-procinfo.h +++ b/sysdeps/s390/dl-procinfo.h @@ -21,7 +21,7 @@ #define _DL_PROCINFO_H 1 #include -#define _DL_HWCAP_COUNT 10 +#define _DL_HWCAP_COUNT 12 #define _DL_PLATFORMS_COUNT 5 @@ -50,6 +50,7 @@ enum HWCAP_S390_ETF3EH = 1 << 8, HWCAP_S390_HIGH_GPRS = 1 << 9, HWCAP_S390_TE = 1 << 10, + HWCAP_S390_VX = 1 << 11, }; #define HWCAP_IMPORTANT (HWCAP_S390_ZARCH | HWCAP_S390_LDISP \ diff --git a/sysdeps/unix/sysv/linux/s390/bits/hwcap.h b/sysdeps/unix/sysv/linux/s390/bits/hwcap.h index 35d47be..986d4a7 100644 --- a/sysdeps/unix/sysv/linux/s390/bits/hwcap.h +++ b/sysdeps/unix/sysv/linux/s390/bits/hwcap.h @@ -35,3 +35,4 @@ #define HWCAP_S390_ETF3EH 256 #define HWCAP_S390_HIGH_GPRS 512 #define HWCAP_S390_TE 1024 +#define HWCAP_S390_VX 2048