From owner-freebsd-arm@freebsd.org Fri Oct 25 07:44:27 2019 Return-Path: Delivered-To: freebsd-arm@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9EE40168F6E for ; Fri, 25 Oct 2019 07:44:27 +0000 (UTC) (envelope-from nikolay.kostirya@i11.co) Received: from mx.i11.co (mx.i11.co [159.69.78.69]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 46zx2f4vYSz4BZl for ; Fri, 25 Oct 2019 07:44:26 +0000 (UTC) (envelope-from nikolay.kostirya@i11.co) Received: from [82.207.42.188] (helo=localhost) by mx.i11.co with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1iNuGl-0004BV-Kt; Fri, 25 Oct 2019 07:44:23 +0000 Date: Fri, 25 Oct 2019 10:44:21 +0300 From: Nick Kostirya To: Konstantin Belousov Cc: freebsd-arm@freebsd.org Subject: Re: ucontext Message-ID: <20191025104421.012c1e5e@i11.co> In-Reply-To: <20191024145436.GX73312@kib.kiev.ua> References: <20191024141133.04fb0693@i11.co> <20191024145436.GX73312@kib.kiev.ua> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; i386-portbld-freebsd11.2) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 46zx2f4vYSz4BZl X-Spamd-Bar: --- X-Spamd-Result: default: False [-3.08 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[i11.co:s=omicron]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:159.69.78.69]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[i11.co:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[i11.co,reject]; FREEMAIL_TO(0.00)[gmail.com]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; IP_SCORE(-0.08)[ipnet: 159.69.0.0/16(1.42), asn: 24940(-1.82), country: DE(-0.01)]; ASN(0.00)[asn:24940, ipnet:159.69.0.0/16, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Oct 2019 07:44:27 -0000 On Thu, 24 Oct 2019 17:54:36 +0300 Konstantin Belousov wrote: > > I believe you want > uc_context.__gregs[_REG_PC] > on arm (32bit) and > uc_context.mc_gpregs.gp_elr > on arm64 for aarch64. > > Sometimes the thumb bit (lowest bit in PC) leaks there, then you should > mask it. Thanks! Although I did not understand your last phrase. There is leak of what? Where can I read about it?