Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp5912932ybp; Tue, 8 Oct 2019 10:04:38 -0700 (PDT) X-Google-Smtp-Source: APXvYqw/izMCre+4+N20FfreTKTZzASXD8FY0YUc/OaUo2FTGu3iJsv2yW7sjB1XOzvbFAsHZlMs X-Received: by 2002:a50:fb16:: with SMTP id d22mr35108791edq.30.1570554277872; Tue, 08 Oct 2019 10:04:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570554277; cv=none; d=google.com; s=arc-20160816; b=DqEgpifOYQIqn5WCxPXfVJN9XAjwxv8SY8TCMI+Eph4qG3KY0y554pD+FM6XKspeWt 6bBeTTpxvEqwcQrOpxPhcsTKXGskpcBr+Sq0kvFj/bva2JuhIi8ug5btHTxo9mtNnuCa Af6i2v9XC1enveSMYeQ7bre3hpRT9XmxbiPTrWm7yVyfQSR7vI8PmUXsytBm8Xy7DL9F /MeqNCESucwbBMZNpBeZHbWjRS3+xyrS/C6OlsIreWq4HfLGmOE6LoHDnc5M8YCqwwDs x6d6QK0ywd7BOEeBfPN7ha7ae0EIiq2gukSorZIxI0lwx304R3NOtYc3pbE+ogAXchLi v6tg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:mail-followup-to:message-id:subject:cc:to:from:date; bh=X9BYErWpi5Oby98Em3HBkcz+9g4v9VW7xUghFfdd/8I=; b=Bh+MERrcMDSHsmMPqAvOGiXM2mNudizVB/PPn9eMrlJJIBWpKKflJFvVMSK305veC/ aZ9owxFg/YjbBDWcXXGOrT6c0hUv2yUZXrodFGH250m6gIW4zGABDRj4LUxgz4iPId6J mOLRIZYfxnQFa4CbNyJMOVWp1aCr7krDwuaG/viPEtkNKpWMeLtkgH1wtj2R9gDXw7BT 2bj6jz+NE9Hj1NclFL2Ok5fcEH/YIenaIYfYrGMLP5IaAJA0FeQ9QPCbN+2o+VdlGrAU CBsjiRDHii8b7f39IAAz3IzW1e9lxp2rJVB5P0sHH1bl09sLWTjUutcwvbwDUK/2rQcN P3vg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l23si10782027edr.187.2019.10.08.10.04.13; Tue, 08 Oct 2019 10:04:37 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727920AbfJHRA6 convert rfc822-to-8bit (ORCPT + 99 others); Tue, 8 Oct 2019 13:00:58 -0400 Received: from mx2.suse.de ([195.135.220.15]:38286 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725966AbfJHRA6 (ORCPT ); Tue, 8 Oct 2019 13:00:58 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 6F213B1FF; Tue, 8 Oct 2019 17:00:56 +0000 (UTC) Date: Tue, 8 Oct 2019 09:59:42 -0700 From: Davidlohr Bueso To: "Koenig, Christian" Cc: "akpm@linux-foundation.org" , "walken@google.com" , "peterz@infradead.org" , "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , "dri-devel@lists.freedesktop.org" , "linux-rdma@vger.kernel.org" , "Deucher, Alexander" , David Airlie , Daniel Vetter , Doug Ledford , Joerg Roedel , J?r?me Glisse , Davidlohr Bueso Subject: Re: [PATCH 09/11] lib/interval-tree: convert interval_tree to half closed intervals Message-ID: <20191008165942.vxfwbectycuersdx@linux-p48b> Mail-Followup-To: "Koenig, Christian" , "akpm@linux-foundation.org" , "walken@google.com" , "peterz@infradead.org" , "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , "dri-devel@lists.freedesktop.org" , "linux-rdma@vger.kernel.org" , "Deucher, Alexander" , David Airlie , Daniel Vetter , Doug Ledford , Joerg Roedel , J?r?me Glisse , Davidlohr Bueso References: <20191003201858.11666-1-dave@stgolabs.net> <20191003201858.11666-10-dave@stgolabs.net> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Disposition: inline Content-Transfer-Encoding: 8BIT In-Reply-To: User-Agent: NeoMutt/20180716 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 04 Oct 2019, Koenig, Christian wrote: >Am 04.10.19 um 08:57 schrieb Christian K?nig: >> Am 03.10.19 um 22:18 schrieb Davidlohr Bueso: >>> The generic tree tree really wants [a, b) intervals, not fully closed. >>> As such convert it to use the new interval_tree_gen.h. Most of the >>> conversions are straightforward, with the exception of perhaps >>> radeon_vm_bo_set_addr(), but semantics have been tried to be left >>> untouched. >> >> NAK, the whole thing won't work. >> >> See we need to handle the full device address space which means we >> have values in the range of 0x0-0xffffffff. >> >> If you make this a closed interval then the end would wrap around to >> 0x0 if long is only 32bit. > >Well I've just now re-read the subject line. From that it sounds like >you are actually trying to fix the interval tree to use a half closed >interval, e.g. something like [a, b[ Correct. > >But your code changes sometimes doesn't seem to reflect that. Hmm the change simply aims at avoiding the end - 1 trick when dealing with interval_tree insertions and lookups; the rest of the series converts other interval tree users in a similar way, albeit some errors which will be updated. What are your concerns about this patch? Thanks, Davidlohr