From owner-freebsd-firewire@FreeBSD.ORG Sat Aug 9 20:12:30 2008 Return-Path: Delivered-To: freebsd-firewire@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 42847106564A; Sat, 9 Aug 2008 20:12:30 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from plato.miralink.com (mail.miralink.com [70.103.185.20]) by mx1.freebsd.org (Postfix) with ESMTP id 18D198FC0C; Sat, 9 Aug 2008 20:12:30 +0000 (UTC) (envelope-from sbruno@miralink.com) Received: from localhost (localhost.localdomain [127.0.0.1]) by plato.miralink.com (Postfix) with ESMTP id D823B1A90DA; Sat, 9 Aug 2008 13:06:58 -0700 (PDT) X-Virus-Scanned: amavisd-new at X-Spam-Flag: NO X-Spam-Score: -4.399 X-Spam-Level: X-Spam-Status: No, score=-4.399 tagged_above=-10 required=6.6 tests=[ALL_TRUSTED=-1.8, AWL=0.000, BAYES_00=-2.599] Received: from plato.miralink.com ([127.0.0.1]) by localhost (plato.miralink.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id koHc5fq-VK6d; Sat, 9 Aug 2008 13:06:58 -0700 (PDT) Received: from [10.47.1.6] (vpn.office.miralink.com [10.0.0.5]) by plato.miralink.com (Postfix) with ESMTP id 2F21C1A8EF0; Sat, 9 Aug 2008 13:06:58 -0700 (PDT) Message-ID: <489DFA2C.4080407@miralink.com> Date: Sat, 09 Aug 2008 13:12:28 -0700 From: Sean Bruno User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: Dieter References: <200808060123.BAA03303@sopwith.solgatos.com> In-Reply-To: <200808060123.BAA03303@sopwith.solgatos.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Scott Long , freebsd-firewire@freebsd.org Subject: Re: This is where I'm going with fwcontrol X-BeenThere: freebsd-firewire@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Firewire support in FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 09 Aug 2008 20:12:30 -0000 Dieter wrote: >> fwcontrol.c: In function 'main': >> fwcontrol.c:726: warning: comparison is always false due to limited range of data type >> >> I changed priority_budget from int to long, is this the correct fix? >> > > I suspect that gcc will still complain on ILP32 machines. > Sorry for the delay...See the attached patch and test it on unpatched 6/7/8 as fwcontrol is the same on all platforms. I implemented your fix for priority_budget, i.e. I should have been paying attention to the conditional test and the assignment from strtol()! Also, I changed some of the variable to check for >= 0 and set their default values to -1. This should have the same effect as adding a new variable as you did in your fix. Let me know what you think! -- Sean Bruno MiraLink Corporation 6015 NE 80th Ave, Ste 100 Portland, OR 97218 Cell 503-358-6832 Phone 503-621-5143 Fax 503-621-5199 MSN: sbruno@miralink.com Google: seanwbruno@gmail.com