AD5AB0F42678796AB347EAF
     +ˆÂÈƒï3Á¾Ê ¿    +/* SPDX-License-Identifier: BSD-3-Clause OR GPL-2.0 */
/* Copyright (c) 2018 Mellanox Technologies. All rights reserved */

#ifndef _OBJAGG_H
#define _OBJAGG_H

struct objagg_ops {
	size_t obj_size;
	bool (*delta_check)(void *priv, const void *parent_obj,
			    const void *obj);
	void * (*delta_create)(void *priv, void *parent_obj, void *obj);
	void (*delta_destroy)(void *priv, void *delta_priv);
	void * (*root_create)(void *priv, void *obj, unsigned int root_id);
#define OBJAGG_OBJ_ROOT_ID_INVALID UINT_MAX
	void (*root_destroy)(void *priv, void *root_priv);
};

struct objagg;
struct objagg_obj;
struct objagg_hints;

const void *objagg_obj_root_priv(const struct objagg_obj *objagg_obj);
const void *objagg_obj_delta_priv(const struct objagg_obj *objagg_obj);
const void *objagg_obj_raw(const struct objagg_obj *objagg_obj);

struct objagg_obj *objagg_obj_get(struct objagg *objagg, void *obj);
void objagg_obj_put(struct objagg *objagg, struct objagg_obj *objagg_obj);
struct objagg *objagg_create(const struct objagg_ops *ops,
			     struct objagg_hints *hints, void *priv);
void objagg_destroy(struct objagg *objagg);

struct objagg_obj_stats {
	unsigned int user_count;
	unsigned int delta_user_count; /* includes delta object users */
};

struct objagg_obj_stats_info {
	struct objagg_obj_stats stats;
	struct objagg_obj *objagg_obj; /* associated object */
	bool is_root;
};

struct objagg_stats {
	unsigned int root_count;
	unsigned int stats_info_count;
	struct objagg_obj_stats_info stats_info[];
};

const struct objagg_stats *objagg_stats_get(struct objagg *objagg);
void objagg_stats_put(const struct objagg_stats *objagg_stats);

enum objagg_opt_algo_type {
	OBJAGG_OPT_ALGO_SIMPLE_GREEDY,
};

struct objagg_hints *objagg_hints_get(struct objagg *objagg,
				      enum objagg_opt_algo_type opt_algo_type);
void objagg_hints_put(struct objagg_hints *objagg_hints);
const struct objagg_stats *
objagg_hints_stats_get(struct objagg_hints *objagg_hints);

#endif
     -�Ç¾Ê      -File not found.
     /ˆÂÈƒn¿Á¾Ê +    //* SPDX-License-Identifier: GPL-2.0-only */
/*
 * SCMI Message Protocol driver NXP extension header
 *
 * Copyright 2024 NXP.
 */

#ifndef _LINUX_SCMI_NXP_PROTOCOL_H
#define _LINUX_SCMI_NXP_PROTOCOL_H

#include <linux/bitfield.h>
#include <linux/device.h>
#include <linux/notifier.h>
#include <linux/types.h>

#define	SCMI_PROTOCOL_IMX_BBM	0x81
#define	SCMI_PROTOCOL_IMX_MISC	0x84

#define SCMI_IMX_VENDOR		"NXP"
#define SCMI_IMX_SUBVENDOR	"IMX"

struct scmi_imx_bbm_proto_ops {
	int (*rtc_time_set)(const struct scmi_protocol_handle *ph, u32 id,
			    uint64_t sec);
	int (*rtc_time_get)(const struct scmi_protocol_handle *ph, u32 id,
			    u64 *val);
	int (*rtc_alarm_set)(const struct scmi_protocol_handle *ph, u32 id,
			     bool enable, u64 sec);
	int (*button_get)(const struct scmi_protocol_handle *ph, u32 *state);
};

enum scmi_nxp_notification_events {
	SCMI_EVENT_IMX_BBM_RTC = 0x0,
	SCMI_EVENT_IMX_BBM_BUTTON = 0x1,
	SCMI_EVENT_IMX_MISC_CONTROL = 0x0,
};

struct scmi_imx_bbm_notif_report {
	bool			is_rtc;
	bool			is_button;
	ktime_t			timestamp;
	unsigned int		rtc_id;
	unsigned int		rtc_evt;
};

struct scmi_imx_misc_ctrl_notify_report {
	ktime_t			timestamp;
	unsigned int		ctrl_id;
	unsigned int		flags;
};

struct scmi_imx_misc_proto_ops {
	int (*misc_ctrl_set)(const struct scmi_protocol_handle *ph, u32 id,
			     u32 num, u32 *val);
	int (*misc_ctrl_get)(const struct scmi_protocol_handle *ph, u32 id,
			     u32 *num, u32 *val);
	int (*misc_ctrl_req_notify)(const struct scmi_protocol_handle *ph,
				    u32 ctrl_id, u32 evt_id, u32 flags);
};
#endif
     1ˆÂÈ„­¼/Á¾Ê ?÷     1// SPDX-License-Identifier: GPL-2.0
/*
 * USB Serial Converter stuff
 *
 *	Copyright (C) 1999 - 2012
 *	    Greg Kroah-Hartman (greg@kroah.com)
 */

#ifndef __LINUX_USB_SERIAL_H
#define __LINUX_USB_SERIAL_H

#include <linux/kref.h>
#include <linux/mutex.h>
#include <linux/serial.h>
#include <linux/kfifo.h>

/* The maximum number of ports one device can grab at once */
#define MA