drm/tests: Add test for drm_atomic_helper_check_modeset()
[drm/drm-misc.git] / arch / x86 / platform / geode / geos.c
blob98027fb1ec32fe783bb0faa29c96122a6ac75f87
1 // SPDX-License-Identifier: GPL-2.0-only
2 /*
3 * System Specific setup for Traverse Technologies GEOS.
4 * At the moment this means setup of GPIO control of LEDs.
6 * Copyright (C) 2008 Constantin Baranov <const@mimas.ru>
7 * Copyright (C) 2011 Ed Wildgoose <kernel@wildgooses.com>
8 * and Philip Prindeville <philipp@redfish-solutions.com>
10 * TODO: There are large similarities with leds-net5501.c
11 * by Alessandro Zummo <a.zummo@towertech.it>
12 * In the future leds-net5501.c should be migrated over to platform
15 #include <linux/kernel.h>
16 #include <linux/init.h>
17 #include <linux/io.h>
18 #include <linux/string.h>
19 #include <linux/dmi.h>
21 #include <asm/geode.h>
23 #include "geode-common.h"
25 static const struct geode_led geos_leds[] __initconst = {
26 { 6, true },
27 { 25, false },
28 { 27, false },
31 static void __init register_geos(void)
33 geode_create_restart_key(3);
34 geode_create_leds("geos", geos_leds, ARRAY_SIZE(geos_leds));
37 static int __init geos_init(void)
39 const char *vendor, *product;
41 if (!is_geode())
42 return 0;
44 vendor = dmi_get_system_info(DMI_SYS_VENDOR);
45 if (!vendor || strcmp(vendor, "Traverse Technologies"))
46 return 0;
48 product = dmi_get_system_info(DMI_PRODUCT_NAME);
49 if (!product || strcmp(product, "Geos"))
50 return 0;
52 printk(KERN_INFO "%s: system is recognized as \"%s %s\"\n",
53 KBUILD_MODNAME, vendor, product);
55 register_geos();
57 return 0;
59 device_initcall(geos_init);