Re: [PATCH 2/2] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-05-08 Thread Lee Jones
> >> This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. > >> > >> commit did use > >> mutex_unlock() in tasklet, but mutex_unlock() can't used in > >> tasklet(atomic context). The driver need use mutex to avoid concurrency, > >> so we can't use tasklet here, the patch need to be removed

Re: [PATCH 2/2] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-05-05 Thread Ulf Hansson
On 29 April 2014 09:36, Ulf Hansson wrote: > On 29 April 2014 03:54, wrote: >> From: Micky Ching >> >> This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. >> >> commit did use >> mutex_unlock() in tasklet, but mutex_unlock() can't used in >> tasklet(atomic context). The driver need u

Re: [PATCH 2/2] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-29 Thread Ulf Hansson
On 29 April 2014 03:54, wrote: > From: Micky Ching > > This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. > > commit did use > mutex_unlock() in tasklet, but mutex_unlock() can't used in > tasklet(atomic context). The driver need use mutex to avoid concurrency, > so we can't use task

[PATCH 2/2] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread micky_ching
From: Micky Ching This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. commit did use mutex_unlock() in tasklet, but mutex_unlock() can't used in tasklet(atomic context). The driver need use mutex to avoid concurrency, so we can't use tasklet here, the patch need to be removed. The sp

Re: [PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread Ulf Hansson
On 28 April 2014 14:29, Lee Jones wrote: >> >> From: Micky Ching >> >> >> >> This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. >> > >> > Why was this patch even merged without an MFD Ack? >> > >> >> commit did use >> >> mutex_unlock() in tasklet, but mutex_unlock() can't used in >> >

Re: [PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread Lee Jones
> >> From: Micky Ching > >> > >> This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. > > > > Why was this patch even merged without an MFD Ack? > > > >> commit did use > >> mutex_unlock() in tasklet, but mutex_unlock() can't used in > >> tasklet(atomic context). The driver need use mute

Re: [PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread Dan Carpenter
On Mon, Apr 28, 2014 at 11:53:50AM +0100, Lee Jones wrote: > > From: Micky Ching > > > > This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. > > Why was this patch even merged without an MFD Ack? I think process questions like this are very important. These patches touch both mmc and

Re: [PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread Ulf Hansson
On 28 April 2014 12:53, Lee Jones wrote: >> From: Micky Ching >> >> This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. > > Why was this patch even merged without an MFD Ack? > >> commit did use >> mutex_unlock() in tasklet, but mutex_unlock() can't used in >> tasklet(atomic context).

Re: [PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread Lee Jones
> From: Micky Ching > > This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. Why was this patch even merged without an MFD Ack? > commit did use > mutex_unlock() in tasklet, but mutex_unlock() can't used in > tasklet(atomic context). The driver need use mutex to avoid concurrency, > s

Re: [PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread Ulf Hansson
On 28 April 2014 09:36, wrote: > From: Micky Ching > > This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. > > commit did use > mutex_unlock() in tasklet, but mutex_unlock() can't used in > tasklet(atomic context). The driver need use mutex to avoid concurrency, > so we can't use task

[PATCH] mmc: rtsx: Revert "mmc: rtsx: add support for pre_req and post_req"

2014-04-28 Thread micky_ching
From: Micky Ching This reverts commit c42deffd5b53c9e583d83c7964854ede2f12410d. commit did use mutex_unlock() in tasklet, but mutex_unlock() can't used in tasklet(atomic context). The driver need use mutex to avoid concurrency, so we can't use tasklet here, the patch need to be removed. The sp

Re: Locking issues in "mmc: rtsx: add support for pre_req and post_req"

2014-04-21 Thread micky
Hi Peter, I'm considering not using spinlock to get it work and will resend the patch later. Thank you. Best Regards. micky On 04/19/2014 07:13 AM, Peter Wu wrote: So, I reverted c42deffd5b53c9e583d83c7964854ede2f12410d ("mmc: rtsx: add support for pre_req and post_req") on t

Locking issues in "mmc: rtsx: add support for pre_req and post_req" (was: Re: [PATCH] mmc: rtsx: fix possible circular locking dependency)

2014-04-18 Thread Peter Wu
So, I reverted c42deffd5b53c9e583d83c7964854ede2f12410d ("mmc: rtsx: add support for pre_req and post_req") on top of v3.15-rc1-49-g10ec34f and the hang issue went away. There is something that is possibly problematic. All three tasklets (cmd, data, finish) try to spinlock on

Re: mmc: rtsx: add support for pre_req and post_req

2014-03-02 Thread micky
On 03/01/2014 04:35 AM, Dan Carpenter wrote: Hello Micky Ching, The patch c42deffd5b53: "mmc: rtsx: add support for pre_req and post_req" from Feb 17, 2014, leads to the following static checker warning: drivers/mmc/host/rtsx_pci_sdmmc.c:525 sd_pre_dma_transfer()

re: mmc: rtsx: add support for pre_req and post_req

2014-02-28 Thread Dan Carpenter
Hello Micky Ching, The patch c42deffd5b53: "mmc: rtsx: add support for pre_req and post_req" from Feb 17, 2014, leads to the following static checker warning: drivers/mmc/host/rtsx_pci_sdmmc.c:525 sd_pre_dma_transfer() warn: we tested 'next' before and it was

Re: mmc: rtsx: add support for pre_req and post_req

2014-02-25 Thread Dan Carpenter
On Tue, Feb 25, 2014 at 09:52:12AM +0800, micky wrote: > Hi Dan, > > I'm wondering how to get this warning info, so I can check before > sending patch. > Can you give me some idea? > This is a smatch thing, but you it's a cross function bug so you have to build the database first and that takes

Re: mmc: rtsx: add support for pre_req and post_req

2014-02-24 Thread micky
patch c42deffd5b53: "mmc: rtsx: add support for pre_req and post_req" from Feb 17, 2014, leads to the following Smatch complaint: drivers/mmc/host/rtsx_pci_sdmmc.c:194 sd_finish_request() error: we previously assumed 'mrq' could be null (see line 158) drivers/mmc/host/rtsx_pci_sd

re: mmc: rtsx: add support for pre_req and post_req

2014-02-24 Thread Dan Carpenter
Hello Micky Ching, This is a semi-automatic email about new static checker warnings. The patch c42deffd5b53: "mmc: rtsx: add support for pre_req and post_req" from Feb 17, 2014, leads to the following Smatch complaint: drivers/mmc/host/rtsx_pci_sdmmc.c:194 sd_finish_request()

re: mmc: rtsx: add support for pre_req and post_req

2014-02-24 Thread Dan Carpenter
Hello Micky Ching, This is a semi-automatic email about new static checker warnings. The patch c42deffd5b53: "mmc: rtsx: add support for pre_req and post_req" from Feb 17, 2014, leads to the following Smatch complaint: drivers/mmc/host/rtsx_pci_sdmmc.c:504 sd_get_rsp()

[PATCH v2 3/3] mmc: rtsx: add support for pre_req and post_req

2014-02-17 Thread micky_ching
From: Micky Ching Add support for non-blocking request, pre_req() runs dma_map_sg() and post_req() runs dma_unmap_sg(). This patch can increase card read/write speed, especially for high speed card and slow CPU(for some embedded platform). Users can get a great benefit from this patch. if CPU fr

[PATCH RESEND 3/3] mmc: rtsx: add support for pre_req and post_req

2014-02-16 Thread micky_ching
From: Micky Ching Add support for non-blocking request, pre_req() runs dma_map_sg() and post_req() runs dma_unmap_sg(). This patch can increase card read/write speed, especially for high speed card and slow CPU(for some embedded platform). Users can get a great benefit from this patch. if CPU fr

[PATCH 3/3] mmc: rtsx: add support for pre_req and post_req

2014-01-08 Thread micky_ching
From: Micky Ching Add support for non-blocking request, pre_req() runs dma_map_sg() and post_req() runs dma_unmap_sg(). This patch can increase card read/write speed, especially for high speed card and slow CPU(for some embedded platform). Users can get a great benefit from this patch. if CPU fr