mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2025-09-19 21:01:51 +02:00
When bringing in the series 'arm: dts: am62-beagleplay: Fix Beagleplay Ethernet"' I failed to notice that b4 noticed it was based on next and so took that as the base commit and merged that part of next to master. This reverts commit c8ffd1356d42223cbb8c86280a083cc3c93e6426, reversing changes made to 2ee6f3a5f7550de3599faef9704e166e5dcace35. Reported-by: Jonas Karlman <jonas@kwiboo.se> Signed-off-by: Tom Rini <trini@konsulko.com>
37 lines
759 B
C
37 lines
759 B
C
// SPDX-License-Identifier: GPL-2.0-or-later
|
|
/*
|
|
* Copyright (c) 2022 Sartura Ltd.
|
|
* Written by Robert Marko <robert.marko@sartura.hr>
|
|
*
|
|
* Sandbox driver for the thermal uclass.
|
|
*/
|
|
|
|
#include <common.h>
|
|
#include <dm.h>
|
|
#include <thermal.h>
|
|
|
|
int sandbox_thermal_get_temp(struct udevice *dev, int *temp)
|
|
{
|
|
/* Simply return 100 deg C */
|
|
*temp = 100;
|
|
|
|
return 0;
|
|
}
|
|
|
|
static const struct dm_thermal_ops sandbox_thermal_ops = {
|
|
.get_temp = sandbox_thermal_get_temp,
|
|
};
|
|
|
|
static const struct udevice_id sandbox_thermal_ids[] = {
|
|
{ .compatible = "sandbox,thermal" },
|
|
{ }
|
|
};
|
|
|
|
U_BOOT_DRIVER(thermal_sandbox) = {
|
|
.name = "thermal-sandbox",
|
|
.id = UCLASS_THERMAL,
|
|
.of_match = sandbox_thermal_ids,
|
|
.ops = &sandbox_thermal_ops,
|
|
.flags = DM_FLAG_PRE_RELOC,
|
|
};
|