PCI: endpoint: pci-epf-test: Clean up pci_epf_test_unbind()
authorNiklas Cassel <cassel@kernel.org>
Wed, 20 Mar 2024 11:31:52 +0000 (12:31 +0100)
committerKrzysztof Wilczyński <kwilczynski@kernel.org>
Wed, 10 Apr 2024 18:02:04 +0000 (18:02 +0000)
commit597ac0fa37b86833203c6c73ecbaa72ccc3781bd
treeb5f1d719fbd43d9c3c13f71880f51d07b185a21d
parente49eab944cfb3c0281100ab61e1c5d229e0f7b18
PCI: endpoint: pci-epf-test: Clean up pci_epf_test_unbind()

Clean up pci_epf_test_unbind() by using a continue if we did not allocate
memory for the BAR index. This reduces the indentation level by one.

This makes pci_epf_test_unbind() more similar to pci_epf_test_set_bar().

Link: https://lore.kernel.org/linux-pci/20240320113157.322695-6-cassel@kernel.org
Signed-off-by: Niklas Cassel <cassel@kernel.org>
Signed-off-by: Krzysztof Wilczyński <kwilczynski@kernel.org>
Reviewed-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
drivers/pci/endpoint/functions/pci-epf-test.c