1. 17 4月, 2008 7 次提交
  2. 15 4月, 2008 3 次提交
  3. 07 4月, 2008 1 次提交
  4. 03 4月, 2008 4 次提交
  5. 01 4月, 2008 1 次提交
  6. 26 3月, 2008 3 次提交
  7. 24 3月, 2008 3 次提交
  8. 11 3月, 2008 1 次提交
  9. 07 3月, 2008 1 次提交
  10. 26 2月, 2008 1 次提交
  11. 21 2月, 2008 1 次提交
  12. 14 2月, 2008 1 次提交
  13. 07 2月, 2008 1 次提交
  14. 06 2月, 2008 3 次提交
    • J
      [POWERPC] arch/powerpc/sysdev: Add missing of_node_put · b1725c93
      Julia Lawall 提交于
      The functions of_find_compatible_node and of_find_node_by_type both
      call of_node_get on their result.  So any error handling code
      thereafter should call of_node_put(np).  This is taken care of in the
      case where there is a goto out, but not when there is a direct return.
      
      The function irq_alloc_host puts np into the returned structure, which is
      stored in the global variable mpc8xx_pic_host, so the reference count
      should be set for the lifetime of that variable.  The current solution ups
      the reference count again in the argument to irq_alloc_host so that it can
      be decremented on the way out.  This seems a bit unnecessary, and also
      doesn't work in the case where irq_alloc_host fails, because then the
      reference count only goes does by one, whereas it should go down by two.  A
      better solution is to not increment the reference count in the argument to
      irq_alloc_host and only decrement it on the way out in an error case.
      
      The problem was found using the following semantic match.
      (http://www.emn.fr/x-info/coccinelle/)
      
      // <smpl>
      @@
      type T,T1,T2;
      identifier E;
      statement S;
      expression x1,x2,x3;
      int ret;
      @@
      
        T E;
        ...
      * E = \(of_get_parent\|of_find_compatible_node\)(...);
        if (E == NULL) S
        ... when != of_node_put(...,(T1)E,...)
            when != if (E != NULL) { ... of_node_put(...,(T1)E,...); ...}
            when != x1 = (T1)E
            when != E = x3;
            when any
        if (...) {
          ... when != of_node_put(...,(T2)E,...)
              when != if (E != NULL) { ... of_node_put(...,(T2)E,...); ...}
              when != x2 = (T2)E
      (
      *   return;
      |
      *   return ret;
      )
        }
      // </smpl>
      Signed-off-by: NJulia Lawall <julia@diku.dk>
      Cc: Stephen Rothwell <sfr@canb.auug.org.au>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Kumar Gala <galak@gate.crashing.org>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      b1725c93
    • A
      [POWERPC] qe_lib: fix few fluffy negligences · d8985fd2
      Anton Vorontsov 提交于
      One is intoduced by me (of_node_put() absence) and another was
      present already (not checking for NULL).
      
      Found by Stephen Rothwell.
      Signed-off-by: NAnton Vorontsov <avorontsov@ru.mvista.com>
      Acked-by: NStephen Rothwell <sfr@canb.auug.org.au>
      Signed-off-by: NKumar Gala <galak@kernel.crashing.org>
      d8985fd2
    • K
      [POWERPC] FSL: fix mpc83xx_spi device registration · dc4e4207
      Kim Phillips 提交于
      calling platform_device_register after platform_device_alloc causes
      this:
      
      kobject (c3841a70): tried to init an initialized object, something is seriously wrong.
      Call Trace:
      [c381fe20] [c0007bb8] show_stack+0x3c/0x194 (unreliable)
      [c381fe50] [c01322a8] kobject_init+0xb8/0xbc
      [c381fe60] [c01591cc] device_initialize+0x30/0x9c
      [c381fe80] [c015ee34] platform_device_register+0x1c/0x34
      [c381fea0] [c02f1fe0] of_fsl_spi_probe+0x21c/0x22c
      [c381ff30] [c02f2044] fsl_spi_init+0x54/0x160
      [c381ff60] [c02f3924] __machine_initcall_mpc832x_rdb_mpc832x_spi_init+0x120/0x138
      [c381ff70] [c02e61b4] kernel_init+0x98/0x284
      [c381fff0] [c000f740] kernel_thread+0x44/0x60
      
      fixed by calling platform_device_add (second half of
      platform_device_register) instead.
      Signed-off-by: NKim Phillips <kim.phillips@freescale.com>
      Signed-off-by: NKumar Gala <galak@kernel.crashing.org>
      dc4e4207
  15. 28 1月, 2008 8 次提交
  16. 27 1月, 2008 1 次提交