[lkml]   [2007]   [Sep]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH 5/5] Add DMA engine driver for Freescale MPC85xxprocessors.
    On Thu, Sep 13, 2007 at 03:13:06AM -0700, Zhang Wei-r63237 wrote:
    > > After dropping the lock, you can no longer assume that your
    > > iterator is
    > > still valid; you need to work off of the list head.
    > >
    > list_for_each_entry_safe() is used here. I think the safe should be ok.
    > :P

    Nope. The safety is against the particular item you're iterating on
    being removed; it doesn't protect against the *next* entry being removed
    when you drop the lock.

    > > Why not use an array of channels?
    > The list is used in dma engine core file. And it's possible that there
    > are not all channel listed in dts and array.

    I'm not sure I understand what you mean by the latter comment...

    > > You could have the features be part of the match struct, so
    > > you don't have
    > > to do extra strcmps.
    > >
    > Can I use the data field of struct of_device_id?

    Yes, that's what it's there for. :-)

    > > > +static struct of_device_id of_fsl_dma_ids[] = {
    > > > + { .compatible = "fsl,dma", },
    > > > +};
    > >
    > > Why do we need to bind to the parent node at all?
    > Yes, the MPC83xx should get interrupt source from DMA device register.

    You don't need to bind to it for that, though -- just call of_get_parent
    from the channel probe. Though it might be easier to bind to the parent
    to ensure that you only register the IRQ once.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2007-09-13 16:51    [W:0.031 / U:9.076 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site