2 * This file is part of the coreboot project.
4 * Copyright (C) 2007-2009 coresystems GmbH
5 * Copyright (C) 2012 The Chromium OS Authors
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License as
9 * published by the Free Software Foundation; version 2 of
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
19 #include <console/console.h>
20 #include <device/device.h>
21 #include <device/pci.h>
22 #include <device/pci_ids.h>
23 #include "sandybridge.h"
25 enum platform_type
get_platform_type(void)
27 const int id
= get_platform_id();
28 if (id
!= 1 && id
!= 4)
29 printk(BIOS_WARNING
, "WARN: Unknown platform id 0x%x\n", id
);
31 return (id
== 4) ? PLATFORM_MOBILE
: PLATFORM_DESKTOP_SERVER
;