Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753994AbaBQWqw (ORCPT ); Mon, 17 Feb 2014 17:46:52 -0500 Received: from mail-pd0-f171.google.com ([209.85.192.171]:39325 "EHLO mail-pd0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753907AbaBQWqt (ORCPT ); Mon, 17 Feb 2014 17:46:49 -0500 Date: Mon, 17 Feb 2014 14:46:45 -0800 From: Kent Overstreet To: Randy Dunlap Cc: Geert Uytterhoeven , Linux Kernel Mailing List , linux-bcache@vger.kernel.org Subject: Re: New bcache compiler warning (was: Re: bcache: Minor fixes from kbuild robot) Message-ID: <20140217224645.GC11655@kmo> References: <530279EC.5010605@infradead.org> <20140217214553.GB11655@kmo> <530290DF.1060008@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <530290DF.1060008@infradead.org> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Feb 17, 2014 at 02:44:47PM -0800, Randy Dunlap wrote: > Could that cause a truncation? unsigned means unsigned int. > Can unsigned int be smaller (fewer bits) than the k pointer? > If so, is that OK or a problem? It's just truncating the offset of the pointer within the struct bset, which is part of a btree node - the thing that's being cast is restricted to be no bigger than a btree node, which is at most a few mb. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/