From owner-freebsd-current@FreeBSD.ORG Thu Dec 4 11:24:29 2008 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61ECA106564A for ; Thu, 4 Dec 2008 11:24:29 +0000 (UTC) (envelope-from yanefbsd@gmail.com) Received: from rv-out-0506.google.com (rv-out-0506.google.com [209.85.198.234]) by mx1.freebsd.org (Postfix) with ESMTP id 2A2658FC08 for ; Thu, 4 Dec 2008 11:24:29 +0000 (UTC) (envelope-from yanefbsd@gmail.com) Received: by rv-out-0506.google.com with SMTP id b25so3854057rvf.43 for ; Thu, 04 Dec 2008 03:24:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to :subject:cc:in-reply-to:mime-version:content-type :content-transfer-encoding:content-disposition:references; bh=Sg5+b9u/6cnipKk7glL/8nLc7EBc/wdDGb/1y3QKLSY=; b=lfhZhPVPxJgAJmRcUaaISM/jT05COUol+7oW0bqSxne5Fd4DHrY+OhUCIN7/o5Mken XAaP2YKJcsHQ5qBY+3vCUEbLRR/TbCSTEF3pq6l0fn7n0g3K6aQtK1xouhaV39M090pX gS/nsMNRI9eo7rDjLo0qKenP6ZvHo8CQ6gLVk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version :content-type:content-transfer-encoding:content-disposition :references; b=P1lPC/k4u5kzhg02CVEN2wt258m5hxIsPrMwMq0KB2IQI1LF+IMVMsshAaUFN0/GMU OF8cOkADfjo/7apbHGOxYi4H3aFHunwCqFnN1VfKm5734Cvvsm4Z/WzuWa79DdND2wdK lpUlnNaqPLxJZv/eoXw2ITm0FOYR0uoakwWGM= Received: by 10.141.26.19 with SMTP id d19mr6872734rvj.184.1228389868758; Thu, 04 Dec 2008 03:24:28 -0800 (PST) Received: by 10.140.158.13 with HTTP; Thu, 4 Dec 2008 03:24:28 -0800 (PST) Message-ID: <7d6fde3d0812040324y3bf0901cy1f4a6d961362c314@mail.gmail.com> Date: Thu, 4 Dec 2008 03:24:28 -0800 From: "Garrett Cooper" To: "Maksim Yevmenkin" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Cc: "current@freebsd.org" Subject: Re: RFC: small syscons and kbd patch X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Dec 2008 11:24:29 -0000 On Tue, Dec 2, 2008 at 5:01 PM, Maksim Yevmenkin wrote: > Dear Hackers, > > can someone please review the attached small patch for syscons and > kbd? it should be a no-op mostly. the patch basically does > > 1) removes bogus layering in syscons, i.e. basically removes sccngetch(); > 2) implements advisory lock for kbd (based on atomic(9)); > 3) implements new POLLED flag for kbd; > > this is a part of a plan to fix keyboard access races in syscons. > > thanks, > max Max, Why are you double and triple negating on this line? + return (atomic_cmpset_acq_int(&kbd->kb_locked, !!!on, !!on)); -Garrett