Staging
v0.8.1
https://github.com/torvalds/linux
Raw File
Tip revision: 5816b3e6577eaa676ceb00a848f0fd65fe2adc29 authored by Linus Torvalds on 26 September 2021, 21:08:19 UTC
Linux 5.15-rc3
Tip revision: 5816b3e
schid.h
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef ASM_SCHID_H
#define ASM_SCHID_H

#include <linux/string.h>
#include <uapi/asm/schid.h>

/* Helper function for sane state of pre-allocated subchannel_id. */
static inline void
init_subchannel_id(struct subchannel_id *schid)
{
	memset(schid, 0, sizeof(struct subchannel_id));
	schid->one = 1;
}

static inline int
schid_equal(struct subchannel_id *schid1, struct subchannel_id *schid2)
{
	return !memcmp(schid1, schid2, sizeof(struct subchannel_id));
}

#endif /* ASM_SCHID_H */
back to top