From patchwork Tue Sep 7 14:33:22 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Gleixner X-Patchwork-Id: 178142 Return-path: X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on void.printf.net X-Spam-Level: X-Spam-Status: No, score=-1.0 required=2.9 tests=RCVD_IN_DNSWL_LOW autolearn=disabled version=3.2.5 Envelope-to: chris@printf.net Delivery-date: Tue, 07 Sep 2010 15:35:42 +0100 Received: from lists.laptop.org ([18.85.2.145] helo=mail.laptop.org) by void.printf.net with esmtp (Exim 4.69) (envelope-from ) id 1OszGw-000595-D0 for chris@printf.net; Tue, 07 Sep 2010 15:35:42 +0100 Received: by mail.laptop.org (Postfix) id A94CA24968; Tue, 7 Sep 2010 10:35:22 -0400 (EDT) Delivered-To: cjb@laptop.org Received: from spam.laptop.org (spam.laptop.org [18.85.46.23]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.laptop.org (Postfix) with ESMTPS id 91C8C24881 for ; Tue, 7 Sep 2010 10:35:22 -0400 (EDT) X-ASG-Debug-ID: 1283870112-0b740d55000b-zHW3sV Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by spam.laptop.org with ESMTP id XQDdkPdAwHEcJz9M for ; Tue, 07 Sep 2010 10:35:31 -0400 (EDT) X-Barracuda-Envelope-From: linux-mmc-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932246Ab0IGOd4 (ORCPT ); Tue, 7 Sep 2010 10:33:56 -0400 Received: from www.tglx.de ([62.245.132.106]:43871 "EHLO www.tglx.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932219Ab0IGOdl (ORCPT ); Tue, 7 Sep 2010 10:33:41 -0400 Received: from localhost6.localdomain6 (www.tglx.de [127.0.0.1]) by www.tglx.de (8.13.8/8.13.8/TGLX-2007100201) with ESMTP id o87EXMde010424; Tue, 7 Sep 2010 16:33:22 +0200 Message-Id: <20100907125056.703221226@linutronix.de> User-Agent: quilt/0.47-1 Date: Tue, 07 Sep 2010 14:33:22 -0000 From: Thomas Gleixner To: LKML Cc: Andrew Morton , Ingo Molnar , Peter Zijlstra , Christoph Hellwig , linux-mmc@vger.kernel.org X-ASG-Orig-Subj: [patch 21/30] mmc: Convert "mutex" to semaphore Subject: [patch 21/30] mmc: Convert "mutex" to semaphore References: <20100907124636.880953480@linutronix.de> Content-Disposition: inline; filename=drivers-mmc-card-queue-sema.patch X-Virus-Scanned: clamav-milter 0.95.3 at www.tglx.de X-Virus-Status: Clean Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Barracuda-Connect: vger.kernel.org[209.132.180.67] X-Barracuda-Start-Time: 1283870130 X-Barracuda-URL: http://18.85.46.23:8000/cgi-mod/mark.cgi X-Virus-Scanned: by bsmtpd at laptop.org X-Barracuda-Spam-Score: 0.00 X-Barracuda-Spam-Status: No, SCORE=0.00 using global scores of TAG_LEVEL=3.5 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=5.5 tests= X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.2.40194 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- Index: linux-2.6/drivers/mmc/card/queue.c =================================================================== --- linux-2.6.orig/drivers/mmc/card/queue.c +++ linux-2.6/drivers/mmc/card/queue.c @@ -209,7 +209,7 @@ int mmc_init_queue(struct mmc_queue *mq, sg_init_table(mq->sg, host->max_phys_segs); } - init_MUTEX(&mq->thread_sem); + sema_init(&mq->thread_sem, 1); mq->thread = kthread_run(mmc_queue_thread, mq, "mmcqd"); if (IS_ERR(mq->thread)) {