From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 114673 invoked by alias); 5 Nov 2019 00:50:20 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 114665 invoked by uid 89); 5 Nov 2019 00:50:20 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=0.9 required=5.0 tests=AWL,BAYES_50,KAM_LOTSOFHASH,KAM_SHORT,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=no version=3.3.1 spammy=ack, qTStatus, $qtstatus, qsupported X-HELO: mail-qk1-f171.google.com Received: from mail-qk1-f171.google.com (HELO mail-qk1-f171.google.com) (209.85.222.171) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 05 Nov 2019 00:50:18 +0000 Received: by mail-qk1-f171.google.com with SMTP id m16so19229354qki.11 for ; Mon, 04 Nov 2019 16:50:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=pv+cGGv+vyvMF1eyk0R/x86rP90siYm3Bx0z0c0glEA=; b=AbAUnjerbk5w8NXvhnPQ8xqhukPw9/6kkYYQ04Nz9acIXuOEDmGkOfRZQZryTbkSHA Ha/F/l8qlC6HstJ3Rgqp0hGHbKEapZwBAfGB+15OhgRzCTS7MhvC41IH7jX1o94/keFY sKyoQg4ZWP5PyViYHwaka47loOaK/rZBJIBhzaSO4a/j8kqV/ipH6LUTxVwqcGL7wAsw dXaG26Cn+ShI/csCHtTw0FUWDVerb68xfbNvUlGllZbRa2f005B6AyqCvn6fMs/Rh+zw v9DjdTKyL9eROgdFRTKU9BPRxIuwJKtsapRLCbyY4Q+07oWGR/PPP3DErGaoSj6gitiS 2Vug== Return-Path: Received: from [192.168.15.21] (201-43-10-147.dsl.telesp.net.br. [201.43.10.147]) by smtp.gmail.com with ESMTPSA id l5sm7667824qtj.52.2019.11.04.16.50.14 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 04 Nov 2019 16:50:15 -0800 (PST) Subject: Re: gdb 8.3.1 truncated register in remote g packet To: Reinoud Koornstra Cc: gdb@sourceware.org References: <5c9d0ab7-4e03-ea43-ae54-5d2aed0728e0@linaro.org> <0d7d8ede-1cae-c0cc-be35-05443dc5f073@linaro.org> <1b1ebf11-3e2c-d5b3-6a5b-50ed54e791bc@linaro.org> From: Luis Machado Message-ID: Date: Tue, 05 Nov 2019 00:50:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-IsSubscribed: yes X-SW-Source: 2019-11/txt/msg00011.txt.bz2 Hi Reinoud, On 11/4/19 2:52 PM, Reinoud Koornstra wrote: > > You might have gotten lucky. Or GDB wasn't too restrictive on the > checks. > > > True > > > > > >     Just to confirm, does your arm target have floating point > registers? > > > > Good point, I did assume it has, because in some cases armeabihf was > > used to compile, but not in all cases, I'll check whether it is, > > otherwise I'd have to recompile gdb without hf. > > I'll get the info and let you know, thanks for helping out! > > > Yes, the arm cpu used has floating point registers > > > Well, it seems GDB assumes floating point registers are there by > default, so there wouldn't be a need to build GDB specifically for that. > > > I did compile a gdb 7.7.1,  i compiled earlier 7.0 (failed to compile > without removing Werror in bfd directory Makefile...), then I tried > 7.4.1, but both of these versions didn't support remote baud rate. > However 7.7.1 worked nicely, well way better: (I did go echo g > > /proc/sysrq-trigger to get it waiting for gdb). This indicates something might have changed that made newer GDB's grumpy at your kgdb instance. Would you mind opening a ticket here (https://sourceware.org/bugzilla/) so we can track this properly? I'll do some more investigation. If you don't have an account i can do it for you, from information we exchanged through e-mail. > GNU gdb (GDB) 7.7.1 > Copyright (C) 2014 Free Software Foundation, Inc. > License GPLv3+: GNU GPL version 3 or later > > This is free software: you are free to change and redistribute it. > There is NO WARRANTY, to the extent permitted by law.  Type "show copying" > and "show warranty" for details. > This GDB was configured as "--host=x86_64-unknown-linux-gnu > --target=arm-linux-gnueabihf". > Type "show configuration" for configuration details. > For bug reporting instructions, please see: > . > Find the GDB manual and other documentation resources online at: > . > For help, type "help". > Type "apropos word" to search for commands related to "word"... > Reading symbols from ./vmlinux...done. > (gdb) set serial baud 115200 > (gdb) set debug remote 1 > (gdb) target remote /dev/ttyUSB4 > Remote debugging using /dev/ttyUSB4 > Sending packet: $qSupported:multiprocess+;qRelocInsn+#2a...Ack > Packet received: > Packet qSupported (supported-packets) is NOT supported > Sending packet: $Hg0#df...Ack > Packet received: OK > Sending packet: $qTStatus#49...Ack > Packet received: > Packet qTStatus (trace-status) is NOT supported > Sending packet: $?#3f...Ack > Packet received: S05 > Sending packet: $Hc-1#09...Ack > Packet received: OK > Sending packet: $qC#b4...Ack > Packet received: QC1fbb > Sending packet: $qAttached#8f...Ack > Packet received: > Packet qAttached (query-attached) is NOT supported > Sending packet: $qOffsets#4b...Ack > Packet received: > Sending packet: $g#67...Ack > Packet received: > 0000000001000000b0829e80ac829e8054829880b4a698806700000013000060060000000000000000000000cc5e0bbfd05e0bbfc05e0bbf10200a80581f0a8000000000000000000000000000000000000000000000000000000000000000000000000000000000 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > Sending packet: $m800a1f54,4#c6...Ack > Packet received: 4ef07ff5 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > Sending packet: $m800a1f54,4#c6...Ack > Packet received: 4ef07ff5 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > Sending packet: $m800a1f54,4#c6...Ack > Packet received: 4ef07ff5 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > Sending packet: $m800a1f54,4#c6...Ack > Packet received: 4ef07ff5 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > Sending packet: $m800a1f58,4#ca...Ack > Packet received: ffdeffe7 > 0x800a1f58 in arch_kgdb_breakpoint () at kernel/debug/debug_core.c:1049 > 1049    kernel/debug/debug_core.c: No such file or directory. > Sending packet: $qSymbol::#5b...Ack > Packet received: > Packet qSymbol (symbol-lookup) is NOT supported > (gdb) set debug remote 0 > (gdb) bt full > #0  0x800a1f58 in arch_kgdb_breakpoint () at kernel/debug/debug_core.c:1049 > No locals. > #1  kgdb_breakpoint () at kernel/debug/debug_core.c:1050 > No locals. > #2  0x800a2010 in sysrq_handle_dbg (key=0) at kernel/debug/debug_core.c:810 > No locals. > #3  0x80367308 in __handle_sysrq (key=103, check_mask=false) at > drivers/tty/sysrq.c:535 >         op_p = 0x8098a6b4 >         orig_log_level = 6 >         i = -2137479500 >         flags = 1610612755 > #4  0x8036745c in write_sysrq_trigger (file=0x0 <__vectors_start>, > buf=0x1 <__vectors_start> , > count=2, ppos=0x809e82ac ) at drivers/tty/sysrq.c:1083 > No locals. > #5  0x80177e18 in proc_reg_write (file=0x0 <__vectors_start>, buf=0x1 > <__vectors_start> , > count=2157871792, ppos=0xbf0b5f78) at fs/proc/inode.c:224 >         write = 0xbf0b5ed0 >         rv = 0 > #6  0x8011fba4 in vfs_write (file=0xbe37bcc0, buf=0xaa408 > "g\nyS0,115200\n", '\337' , \337>..., count=2157871792, pos=0xbf0b5f78) at fs/read_write.c:485 > No locals. > #7  0x801201d4 in SYSC_write (count=, buf= out>, fd=) at fs/read_write.c:534 >         pos = 0 > #8  SyS_write (fd=0, buf=697352, count=2) at fs/read_write.c:526 >         ret = 0 > #9  0x8000f760 in ?? () > No symbol table info available. > Backtrace stopped: previous frame identical to this frame (corrupt stack?)