blob: 1c06cae63074e3dda55926f4d35b3681b89cd268 [file] [log] [blame]
Angel Ponsba38f372020-04-05 15:46:45 +02001/* SPDX-License-Identifier: GPL-2.0-only */
Lee Leahy77ff0b12015-05-05 15:07:29 -07002
Lee Leahy77ff0b12015-05-05 15:07:29 -07003#include <soc/pci_devs.h>
4#include <soc/ramstage.h>
5#include <soc/sata.h>
Lee Leahy77ff0b12015-05-05 15:07:29 -07006#include <device/device.h>
7#include <device/pci.h>
8#include <device/pci_ids.h>
9
10#include "chip.h"
11
Lee Leahy32471722015-04-20 15:20:28 -070012typedef struct soc_intel_braswell_config config_t;
Lee Leahy77ff0b12015-05-05 15:07:29 -070013
14static void sata_init(struct device *dev)
15{
Lee Leahy77ff0b12015-05-05 15:07:29 -070016}
17
Elyes HAOUASb13fac32018-05-24 22:29:44 +020018static void sata_enable(struct device *dev)
Lee Leahy77ff0b12015-05-05 15:07:29 -070019{
Lee Leahy77ff0b12015-05-05 15:07:29 -070020 southcluster_enable_dev(dev);
Lee Leahy77ff0b12015-05-05 15:07:29 -070021}
22
23static struct device_operations sata_ops = {
24 .read_resources = pci_dev_read_resources,
25 .set_resources = pci_dev_set_resources,
26 .enable_resources = pci_dev_enable_resources,
27 .init = sata_init,
28 .enable = sata_enable,
Lee Leahy77ff0b12015-05-05 15:07:29 -070029 .ops_pci = &soc_pci_ops,
30};
31
32static const unsigned short pci_device_ids[] = {
Lee Leahy32471722015-04-20 15:20:28 -070033 AHCI1_DEVID, /* AHCI */
Lee Leahy77ff0b12015-05-05 15:07:29 -070034 0,
35};
36
Lee Leahy32471722015-04-20 15:20:28 -070037static const struct pci_driver soc_sata __pci_driver = {
Lee Leahy77ff0b12015-05-05 15:07:29 -070038 .ops = &sata_ops,
Felix Singer43b7f412022-03-07 04:34:52 +010039 .vendor = PCI_VID_INTEL,
Lee Leahy77ff0b12015-05-05 15:07:29 -070040 .devices = pci_device_ids,
41};