From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933149AbXCYAR1 (ORCPT ); Sat, 24 Mar 2007 20:17:27 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S933159AbXCYAR1 (ORCPT ); Sat, 24 Mar 2007 20:17:27 -0400 Received: from smtp-out.google.com ([216.239.45.13]:3355 "EHLO smtp-out.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933149AbXCYAR0 (ORCPT ); Sat, 24 Mar 2007 20:17:26 -0400 DomainKey-Signature: a=rsa-sha1; s=beta; d=google.com; c=nofws; q=dns; h=received:message-id:date:from:to:subject:cc:in-reply-to: mime-version:content-type:content-transfer-encoding: content-disposition:references; b=MNjS+sx3tXj5oYOna3xYjsVTx9SsWieLz0YW/I5pSg0jXRNjaVJfoAgAkHoPKvgO+ AKJsFeT2wYBF/l5zFYpUA== Message-ID: Date: Sat, 24 Mar 2007 17:17:18 -0700 From: "Ken Chen" To: "Jan Engelhardt" Subject: Re: [PATCH] max_loop limit Cc: "Eric Dumazet" , "Tomas M" , "Linux Kernel Mailing List" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <460236CE.1030303@slax.org> <20070322110058.GB23664@tatooine.rebelbase.local> <46026A92.4020106@slax.org> <20070322144210.73dfaf83.dada1@cosmosbay.com> Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On 3/23/07, Jan Engelhardt wrote: > Sadly, it locks up the foreground process (losetup that would be), and I > have not yet figured out why. And the mpt regression elsewhere is > hindering me in finding out faster. You need to tell the block layer that each loop device is a whole block device, not a partition within another device. Otherwise, I think it will cause a recursive mutex lock in block_dev.c:do_open(). This patch should fix the problem. Signed-off-by: Ken Chen --- ./drivers/block/loop.c.orig 2007-03-24 17:05:51.000000000 -0700 +++ ./drivers/block/loop.c 2007-03-24 17:06:06.000000000 -0700 @@ -1464,6 +1464,7 @@ if ((lo = loop_find_dev(number)) == NULL) { lo = loop_init_one(number); + *part = 0; if (IS_ERR(lo)) return (void *)lo; }