Merge tag 'uuid-for-4.13' of git://git.infradead.org/users/hch/uuid
Pull uuid subsystem from Christoph Hellwig: "This is the new uuid subsystem, in which Amir, Andy and I have started consolidating our uuid/guid helpers and improving the types used for them. Note that various other subsystems have pulled in this tree, so I'd like it to go in early. UUID/GUID summary: - introduce the new uuid_t/guid_t types that are going to replace the somewhat confusing uuid_be/uuid_le types and make the terminology fit the various specs, as well as the userspace libuuid library. (me, based on a previous version from Amir) - consolidated generic uuid/guid helper functions lifted from XFS and libnvdimm (Amir and me) - conversions to the new types and helpers (Amir, Andy and me)" * tag 'uuid-for-4.13' of git://git.infradead.org/users/hch/uuid: (34 commits) ACPI: hns_dsaf_acpi_dsm_guid can be static mmc: sdhci-pci: make guid intel_dsm_guid static uuid: Take const on input of uuid_is_null() and guid_is_null() thermal: int340x_thermal: fix compile after the UUID API switch thermal: int340x_thermal: Switch to use new generic UUID API acpi: always include uuid.h ACPI: Switch to use generic guid_t in acpi_evaluate_dsm() ACPI / extlog: Switch to use new generic UUID API ACPI / bus: Switch to use new generic UUID API ACPI / APEI: Switch to use new generic UUID API acpi, nfit: Switch to use new generic UUID API MAINTAINERS: add uuid entry tmpfs: generate random sb->s_uuid scsi_debug: switch to uuid_t nvme: switch to uuid_t sysctl: switch to use uuid_t partitions/ldm: switch to use uuid_t overlayfs: use uuid_t instead of uuid_be fs: switch ->s_uuid to uuid_t ima/policy: switch to use uuid_t ...
This commit is contained in:
@@ -60,15 +60,13 @@ bool nouveau_is_v1_dsm(void) {
|
||||
}
|
||||
|
||||
#ifdef CONFIG_VGA_SWITCHEROO
|
||||
static const char nouveau_dsm_muid[] = {
|
||||
0xA0, 0xA0, 0x95, 0x9D, 0x60, 0x00, 0x48, 0x4D,
|
||||
0xB3, 0x4D, 0x7E, 0x5F, 0xEA, 0x12, 0x9F, 0xD4,
|
||||
};
|
||||
static const guid_t nouveau_dsm_muid =
|
||||
GUID_INIT(0x9D95A0A0, 0x0060, 0x4D48,
|
||||
0xB3, 0x4D, 0x7E, 0x5F, 0xEA, 0x12, 0x9F, 0xD4);
|
||||
|
||||
static const char nouveau_op_dsm_muid[] = {
|
||||
0xF8, 0xD8, 0x86, 0xA4, 0xDA, 0x0B, 0x1B, 0x47,
|
||||
0xA7, 0x2B, 0x60, 0x42, 0xA6, 0xB5, 0xBE, 0xE0,
|
||||
};
|
||||
static const guid_t nouveau_op_dsm_muid =
|
||||
GUID_INIT(0xA486D8F8, 0x0BDA, 0x471B,
|
||||
0xA7, 0x2B, 0x60, 0x42, 0xA6, 0xB5, 0xBE, 0xE0);
|
||||
|
||||
static int nouveau_optimus_dsm(acpi_handle handle, int func, int arg, uint32_t *result)
|
||||
{
|
||||
@@ -86,7 +84,7 @@ static int nouveau_optimus_dsm(acpi_handle handle, int func, int arg, uint32_t *
|
||||
args_buff[i] = (arg >> i * 8) & 0xFF;
|
||||
|
||||
*result = 0;
|
||||
obj = acpi_evaluate_dsm_typed(handle, nouveau_op_dsm_muid, 0x00000100,
|
||||
obj = acpi_evaluate_dsm_typed(handle, &nouveau_op_dsm_muid, 0x00000100,
|
||||
func, &argv4, ACPI_TYPE_BUFFER);
|
||||
if (!obj) {
|
||||
acpi_handle_info(handle, "failed to evaluate _DSM\n");
|
||||
@@ -138,7 +136,7 @@ static int nouveau_dsm(acpi_handle handle, int func, int arg)
|
||||
.integer.value = arg,
|
||||
};
|
||||
|
||||
obj = acpi_evaluate_dsm_typed(handle, nouveau_dsm_muid, 0x00000102,
|
||||
obj = acpi_evaluate_dsm_typed(handle, &nouveau_dsm_muid, 0x00000102,
|
||||
func, &argv4, ACPI_TYPE_INTEGER);
|
||||
if (!obj) {
|
||||
acpi_handle_info(handle, "failed to evaluate _DSM\n");
|
||||
@@ -259,7 +257,7 @@ static void nouveau_dsm_pci_probe(struct pci_dev *pdev, acpi_handle *dhandle_out
|
||||
if (!acpi_has_method(dhandle, "_DSM"))
|
||||
return;
|
||||
|
||||
supports_mux = acpi_check_dsm(dhandle, nouveau_dsm_muid, 0x00000102,
|
||||
supports_mux = acpi_check_dsm(dhandle, &nouveau_dsm_muid, 0x00000102,
|
||||
1 << NOUVEAU_DSM_POWER);
|
||||
optimus_funcs = nouveau_dsm_get_optimus_functions(dhandle);
|
||||
|
||||
|
@@ -81,10 +81,9 @@ mxm_shadow_dsm(struct nvkm_mxm *mxm, u8 version)
|
||||
{
|
||||
struct nvkm_subdev *subdev = &mxm->subdev;
|
||||
struct nvkm_device *device = subdev->device;
|
||||
static char muid[] = {
|
||||
0x00, 0xA4, 0x04, 0x40, 0x7D, 0x91, 0xF2, 0x4C,
|
||||
0xB8, 0x9C, 0x79, 0xB6, 0x2F, 0xD5, 0x56, 0x65
|
||||
};
|
||||
static guid_t muid =
|
||||
GUID_INIT(0x4004A400, 0x917D, 0x4CF2,
|
||||
0xB8, 0x9C, 0x79, 0xB6, 0x2F, 0xD5, 0x56, 0x65);
|
||||
u32 mxms_args[] = { 0x00000000 };
|
||||
union acpi_object argv4 = {
|
||||
.buffer.type = ACPI_TYPE_BUFFER,
|
||||
@@ -105,7 +104,7 @@ mxm_shadow_dsm(struct nvkm_mxm *mxm, u8 version)
|
||||
* unless you pass in exactly the version it supports..
|
||||
*/
|
||||
rev = (version & 0xf0) << 4 | (version & 0x0f);
|
||||
obj = acpi_evaluate_dsm(handle, muid, rev, 0x00000010, &argv4);
|
||||
obj = acpi_evaluate_dsm(handle, &muid, rev, 0x00000010, &argv4);
|
||||
if (!obj) {
|
||||
nvkm_debug(subdev, "DSM MXMS failed\n");
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user