#17839: Reboot command causes sometimes hanging router with TL-WDR3600 (HW V1.5)
and TL-WDR4300 (HW V1.7)
--------------------------+-----------------------------------
  Reporter:  michaeluray  |      Owner:  developers
      Type:  defect       |     Status:  new
  Priority:  high         |  Milestone:  Barrier Breaker 14.07
 Component:  base system  |    Version:  Barrier Breaker 14.07
Resolution:               |   Keywords:  reboot
--------------------------+-----------------------------------

Comment (by michaeluray):

 I also have tried now the following code, but it did not work. - The
 router was hanging after a reset:
 {{{
 #c!
 void ath79_device_reset_set(u32 mask)
 {
         unsigned long flags;
         u32 reg;
         u32 t;

         if (soc_is_ar71xx())
                 reg = AR71XX_RESET_REG_RESET_MODULE;
         else if (soc_is_ar724x())
                 reg = AR724X_RESET_REG_RESET_MODULE;
         else if (soc_is_ar913x())
                 reg = AR913X_RESET_REG_RESET_MODULE;
         else if (soc_is_ar933x())
                 reg = AR933X_RESET_REG_RESET_MODULE;
         else if (soc_is_ar934x())
                 reg = AR934X_RESET_REG_RESET_MODULE;
         else if (soc_is_qca953x())
                 reg = QCA953X_RESET_REG_RESET_MODULE;
         else if (soc_is_qca955x())
                 reg = QCA955X_RESET_REG_RESET_MODULE;
         else
                 panic("Reset register not defined for this SOC");

         spin_lock_irqsave(&ath79_device_reset_lock, flags);
         t = ath79_reset_rr(reg);
         if (mask == AR71XX_RESET_FULL_CHIP)
                 ath79_reset_wr(reg, mask);
         else
                 ath79_reset_wr(reg, t | mask);
         spin_unlock_irqrestore(&ath79_device_reset_lock, flags);
 }

 }}}

 It looks like as it is important to lock the interrupts, set the reset
 flag and wait there until the CPU reboots.

--
Ticket URL: <https://dev.openwrt.org/ticket/17839#comment:56>
OpenWrt <http://openwrt.org>
Opensource Wireless Router Technology
_______________________________________________
openwrt-tickets mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-tickets

Reply via email to