From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 118621 invoked by alias); 29 Jun 2016 13:56:38 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 118526 invoked by uid 89); 29 Jun 2016 13:56:37 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mail-ob0-f196.google.com Received: from mail-ob0-f196.google.com (HELO mail-ob0-f196.google.com) (209.85.214.196) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-GCM-SHA256 encrypted) ESMTPS; Wed, 29 Jun 2016 13:56:35 +0000 Received: by mail-ob0-f196.google.com with SMTP id qw9so3153977obb.3 for ; Wed, 29 Jun 2016 06:56:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=XKGmQQUAkodW0exQGm17lFEEej1oWXf6CUNxfu1UlL0=; b=lRCy7ZErXucOaxoqaoDUv5stQ3D2Twna+jYsIOffh/XZUNfB0/qpxhpkDTnj8ben5v mEVSh6lsWbxUghX3rCPV7qckLIMI4lcc14drNPj3Xa54DMDdVZ40x0R/AEj2P4N9tkA1 2Bm8QsP7MxK9LkN8egcgv5ydyMVa7Ri5Td6TOR7CU/QtVbMQ/9GI6gHoej/VIJazNZuR U8sWpiTmjwKTVbyGBcRYONNFuTwpgPHVkPTqWWyRvbZR/EloxJF8FTalExI4KOKwFkvp sKR3ORMKqTdnFJIc+FPjn2GQExgnKata/P7jlFVTDItv2ZEKJS74llgndFZOYROn9IOy eufg== X-Gm-Message-State: ALyK8tK25jQBL6jHycdXI+OZer3RH7GJcwrqZMSCcAzI4ndeOFXB3eYZlsbY+o7L6CJ9braInkN5y5XyudQJ3w== X-Received: by 10.202.62.196 with SMTP id l187mr5178156oia.142.1467208593681; Wed, 29 Jun 2016 06:56:33 -0700 (PDT) MIME-Version: 1.0 Received: by 10.202.182.130 with HTTP; Wed, 29 Jun 2016 06:56:33 -0700 (PDT) In-Reply-To: <9e39007b-b89a-4f54-02f3-fc76a77f91cd@redhat.com> References: <1467105996-18063-1-git-send-email-yao.qi@linaro.org> <9e39007b-b89a-4f54-02f3-fc76a77f91cd@redhat.com> From: Yao Qi Date: Wed, 29 Jun 2016 13:56:00 -0000 Message-ID: Subject: Re: [PATCH] Set unknown_syscall differently on arm linux To: Pedro Alves Cc: "gdb-patches@sourceware.org" Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes X-SW-Source: 2016-06/txt/msg00513.txt.bz2 On Wed, Jun 29, 2016 at 10:53 AM, Pedro Alves wrote: > On 06/28/2016 10:26 AM, Yao Qi wrote: >> Currently, we use 123456789 as unknown or illegal syscall number, and >> expect program return ENOSYS. Although 123456789 is an illegal syscall >> number on arm linux, kernel sends SIGILL rather than returns -ENOSYS. >> However, arm linux kernel returns -ENOSYS if syscall number is within >> 0xf0001..0xf07ff, so we can use 0xf07ff for unknown_syscall in test. >> > > I think it'd be good if this was converted to a comment in the source. > OK, I move them into the comments as below, +#if defined(__arm__) +/* Although 123456789 is an illegal syscall umber on arm linux, kernel + sends SIGILL rather than returns -ENOSYS. However, arm linux kernel + returns -ENOSYS if syscall number is within 0xf0001..0xf07ff, so we + can use 0xf07ff for unknown_syscall in test. */ +int unknown_syscall =3D 0x0f07ff; +#else int unknown_syscall =3D 123456789; +#endif patch is pushed in. --=20 Yao (=E9=BD=90=E5=B0=A7)