]> git.baikalelectronics.ru Git - kernel.git/commit
PCI: designware: Check private_data validity in single place
authorLucas Stach <l.stach@pengutronix.de>
Fri, 5 Sep 2014 15:37:55 +0000 (09:37 -0600)
committerBjorn Helgaas <bhelgaas@google.com>
Fri, 5 Sep 2014 15:37:55 +0000 (09:37 -0600)
commit9b74459b8e194b51d9745d0b256e2541189327a6
tree780101865be4d2e993a45a482df09feb64552d03
parent9e1acb69875e288c6e054d4d71a0ece11d44db3b
PCI: designware: Check private_data validity in single place

The driver had checks for this sprinkled all over.  As we call
sys_to_pcie() before every instance of this check, we can move the
check to this single location to make things clear.

Removing the statements after BUG[_ON]() is safe as the kernel is halted at
this point anyway.

Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Acked-by: Jingoo Han <jg1.han@samsung.com>
Acked-by: Mohit Kumar <mohit.kumar@st.com>
drivers/pci/host/pcie-designware.c