device/pci_ops: Drop parameter from pci_bus_default_ops()
A default is a build-time static value, fallback. Return value does not depend of input parameter. Change-Id: I43ae28f465fb46391519ec97a2a50891d458c46d Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/31679 Reviewed-by: Felix Held <felix-coreboot@felixheld.de> Reviewed-by: Aaron Durbin <adurbin@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
		@@ -16,7 +16,7 @@
 | 
				
			|||||||
#include <device/device.h>
 | 
					#include <device/device.h>
 | 
				
			||||||
#include <device/pci_ops.h>
 | 
					#include <device/pci_ops.h>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const struct pci_bus_operations *pci_bus_default_ops(struct device *dev)
 | 
					const struct pci_bus_operations *pci_bus_default_ops(void)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	return &pci_cf8_conf1;
 | 
						return &pci_cf8_conf1;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -27,7 +27,7 @@ static const struct pci_bus_operations *pci_bus_ops(struct bus *bus, struct devi
 | 
				
			|||||||
		bops = bus->dev->ops->ops_pci_bus(dev);
 | 
							bops = bus->dev->ops->ops_pci_bus(dev);
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
	if (!bops)
 | 
						if (!bops)
 | 
				
			||||||
		bops = pci_bus_default_ops(dev);
 | 
							bops = pci_bus_default_ops();
 | 
				
			||||||
	return bops;
 | 
						return bops;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -71,7 +71,7 @@ static const struct pci_bus_operations pci_ops_mmconf = {
 | 
				
			|||||||
	.write32 = pci_mmconf_write_config32,
 | 
						.write32 = pci_mmconf_write_config32,
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
const struct pci_bus_operations *pci_bus_default_ops(struct device *dev)
 | 
					const struct pci_bus_operations *pci_bus_default_ops(void)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	return &pci_ops_mmconf;
 | 
						return &pci_ops_mmconf;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -24,7 +24,7 @@ u32 pci_read_config32(struct device *dev, unsigned int where);
 | 
				
			|||||||
void pci_write_config8(struct device *dev, unsigned int where, u8 val);
 | 
					void pci_write_config8(struct device *dev, unsigned int where, u8 val);
 | 
				
			||||||
void pci_write_config16(struct device *dev, unsigned int where, u16 val);
 | 
					void pci_write_config16(struct device *dev, unsigned int where, u16 val);
 | 
				
			||||||
void pci_write_config32(struct device *dev, unsigned int where, u32 val);
 | 
					void pci_write_config32(struct device *dev, unsigned int where, u32 val);
 | 
				
			||||||
const struct pci_bus_operations *pci_bus_default_ops(struct device *dev);
 | 
					const struct pci_bus_operations *pci_bus_default_ops(void);
 | 
				
			||||||
#endif
 | 
					#endif
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#ifdef __SIMPLE_DEVICE__
 | 
					#ifdef __SIMPLE_DEVICE__
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user