From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9368 invoked by alias); 6 Jul 2011 14:58:12 -0000 Received: (qmail 9360 invoked by uid 22791); 6 Jul 2011 14:58:11 -0000 X-SWARE-Spam-Status: No, hits=-6.9 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 06 Jul 2011 14:57:50 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p66EvjS7016078 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 6 Jul 2011 10:57:45 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p66EviFr025085; Wed, 6 Jul 2011 10:57:44 -0400 Received: from barimba (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id p66EvgR9021605; Wed, 6 Jul 2011 10:57:43 -0400 From: Tom Tromey To: Thiago Jung Bauermann Cc: gdb-patches ml Subject: Re: [RFA] Make ppc-linux-nat insert/remove breakpoint and watchpoint functions return -1. References: <1309897267.3634.6.camel@hactar> Date: Wed, 06 Jul 2011 15:03:00 -0000 In-Reply-To: <1309897267.3634.6.camel@hactar> (Thiago Jung Bauermann's message of "Tue, 05 Jul 2011 17:21:07 -0300") Message-ID: User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain 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 X-SW-Source: 2011-07/txt/msg00192.txt.bz2 >>>>> "Thiago" == Thiago Jung Bauermann writes: Thiago> target_{insert,remove}_{hw_breakpoint,watchpoint,mask_watchpoint} are Thiago> supposed to return 0, 1 and -1 for success, unsupported and error, Thiago> respectively. I looked around for anything saying this, and couldn't find it. Well -- I found it for target_insert_mask_watchpoint, but not other cases. And, at least in breakpoint.c:insert_bp_location, it seems to me that the return value is expected to be an errno in one case -- search for safe_strerror. Maybe this code is in error? I really couldn't say; but it seems inconsistent at best. Perhaps only parts of your patch could go in as-is, what do you think? Tom