From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 3 12:08:00 2011 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A5A67106566B; Sun, 3 Jul 2011 12:08:00 +0000 (UTC) (envelope-from rmh.aybabtu@gmail.com) Received: from mail-pv0-f182.google.com (mail-pv0-f182.google.com [74.125.83.182]) by mx1.freebsd.org (Postfix) with ESMTP id 3153E8FC0A; Sun, 3 Jul 2011 12:07:59 +0000 (UTC) Received: by pvg11 with SMTP id 11so5319342pvg.13 for ; Sun, 03 Jul 2011 05:07:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=F/sDbLKCAINPBBV5Fzm8MF481diFW9FRjKsw/hDi72w=; b=nG/+35B4VdoBWmrfhy5zloXEL7TAmJO0cltbIzusD9VJJ5A6JV7aXdW1DQrBkzdi9D Pj7Z1rTt1dBWVVG+0qi6I+r+2wKpJWg1pL38HX2sqrfLzKFJVubOXxRS/0ln7PzrRw92 oKiP0R+oC+58AwboxBS+YNRq2D8xY2SCuyDBk= MIME-Version: 1.0 Received: by 10.68.25.166 with SMTP id d6mr6147480pbg.136.1309694879431; Sun, 03 Jul 2011 05:07:59 -0700 (PDT) Sender: rmh.aybabtu@gmail.com Received: by 10.68.47.138 with HTTP; Sun, 3 Jul 2011 05:07:59 -0700 (PDT) In-Reply-To: <20110703115750.GL48734@deviant.kiev.zoral.com.ua> References: <20110703115750.GL48734@deviant.kiev.zoral.com.ua> Date: Sun, 3 Jul 2011 14:07:59 +0200 X-Google-Sender-Auth: URUdKaYULLRBLTG9eItUd_zw_d4 Message-ID: From: Robert Millan To: Kostik Belousov Content-Type: text/plain; charset=UTF-8 Cc: freebsd-hackers@freebsd.org, Ed Maste Subject: Re: [PATCH] PAGE_SIZE in libsbuf X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Jul 2011 12:08:00 -0000 2011/7/3 Kostik Belousov : > I think the different workaround is already included in the latest > sbuf source. Please see > http://svnweb.freebsd.org/base/head/sys/kern/subr_sbuf.c?revision=222015&view=markup How does libsbuf react if the guess fails? Also note this codepath isn't tested in FreeBSD (except for pc98). I'm afraid this situation could lead to runtime errors somehow. I'd still propose replacing this guess with a sysconf() check. -- Robert Millan