From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17796 invoked by alias); 1 Jun 2006 17:46:37 -0000 Received: (qmail 17780 invoked by uid 22791); 1 Jun 2006 17:46:36 -0000 X-Spam-Check-By: sourceware.org Received: from intranet.codesourcery.com (HELO mail.codesourcery.com) (65.74.133.6) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 01 Jun 2006 17:46:03 +0000 Received: (qmail 24571 invoked from network); 1 Jun 2006 17:46:00 -0000 Received: from unknown (HELO ?192.168.189.145?) (nathan@127.0.0.2) by mail.codesourcery.com with ESMTPA; 1 Jun 2006 17:46:00 -0000 Message-ID: <447F27BC.6030808@codesourcery.com> Date: Thu, 01 Jun 2006 17:46:00 -0000 From: Nathan Sidwell User-Agent: Mozilla Thunderbird 1.0.8 (X11/20060502) MIME-Version: 1.0 To: Daniel Jacobowitz CC: Eli Zaretskii , gdb-patches@sourceware.org Subject: Re: patch for invalid hw breakpoints References: <447EE9A8.4050800@codesourcery.com> <20060601172639.GA25709@nevyn.them.org> In-Reply-To: <20060601172639.GA25709@nevyn.them.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2006-06/txt/msg00005.txt.bz2 Daniel Jacobowitz wrote: at the watchpoint was completely removed. What am I missing? > > > It caused trouble for a remote stub. If I remember Nathan's example > right, we sent out packets like this: > > -> Z02,1111110 > <- E01 > -> z02,1111110 > > We're asking the stub to remove something that isn't inserted. The > protocol documentation isn't clear on whether stubs have to support > this... but it didn't say that they did, and at least one didn't. The remote stub can deal with this, but the functionality detection code in remote.c cannot. In particular this bit of code in remote_remove_watchpoint triggers because the just attempted remote_insert_watchpoint call has now set the support field to PACKET_DISABLE. if (remote_protocol_packets[PACKET_Z0 + packet].support == PACKET_DISABLE) error (_("Can't clear hardware watchpoints without the '%s' (%s) packet."), remote_protocol_packets[PACKET_Z0 + packet].name, remote_protocol_packets[PACKET_Z0 + packet].title); nathan -- Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery nathan@codesourcery.com :: http://www.planetfall.pwp.blueyonder.co.uk