restore lost packages from 0.2.3 + fix overwritten 0.2.4 files
- Restore 29 recipe symlinks (libdrm, qtbase, dbus, sddm, pipewire, etc.) - Restore 33 patches (KDE, libdrm, mesa, pipewire, sddm, wireplumber) - Restore 20+ local/scripts (audit, lint, test, build helpers) - Restore src/cook/scheduler.rs, status.rs, gnu-config/ - Restore scripts/patch-inclusion-gate.sh, run_mini1.sh, validate-collision-log.sh - Recover TLC source from HEAD (was overwritten by 0.2.3 checkout) - Recover 11 local/docs plans from HEAD (were overwritten) - Recover qt6-wayland-smoke symlink from HEAD - Fix MOTD: remove garbled ASCII art, use clean text - Update version: 0.2.0 -> 0.2.4 in os-release, motd, config - Reduce filesystem_size: 1536 -> 512 MiB - Add ABSOLUTE RULE to AGENTS.md: never delete/ignore packages - Reduce pcid scheme log verbosity: info -> debug
This commit is contained in:
@@ -0,0 +1,64 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 */
|
||||
/* Copyright (C) 2020 ROHM Semiconductors */
|
||||
|
||||
#ifndef LINEAR_RANGE_H
|
||||
#define LINEAR_RANGE_H
|
||||
|
||||
#include <linux/types.h>
|
||||
|
||||
/**
|
||||
* struct linear_range - table of selector - value pairs
|
||||
*
|
||||
* Define a lookup-table for range of values. Intended to help when looking
|
||||
* for a register value matching certaing physical measure (like voltage).
|
||||
* Usable when increment of one in register always results a constant increment
|
||||
* of the physical measure (like voltage).
|
||||
*
|
||||
* @min: Lowest value in range
|
||||
* @min_sel: Lowest selector for range
|
||||
* @max_sel: Highest selector for range
|
||||
* @step: Value step size
|
||||
*/
|
||||
struct linear_range {
|
||||
unsigned int min;
|
||||
unsigned int min_sel;
|
||||
unsigned int max_sel;
|
||||
unsigned int step;
|
||||
};
|
||||
|
||||
#define LINEAR_RANGE(_min, _min_sel, _max_sel, _step) \
|
||||
{ \
|
||||
.min = _min, \
|
||||
.min_sel = _min_sel, \
|
||||
.max_sel = _max_sel, \
|
||||
.step = _step, \
|
||||
}
|
||||
|
||||
#define LINEAR_RANGE_IDX(_idx, _min, _min_sel, _max_sel, _step) \
|
||||
[_idx] = LINEAR_RANGE(_min, _min_sel, _max_sel, _step)
|
||||
|
||||
unsigned int linear_range_values_in_range(const struct linear_range *r);
|
||||
unsigned int linear_range_values_in_range_array(const struct linear_range *r,
|
||||
int ranges);
|
||||
unsigned int linear_range_get_max_value(const struct linear_range *r);
|
||||
|
||||
int linear_range_get_value(const struct linear_range *r, unsigned int selector,
|
||||
unsigned int *val);
|
||||
int linear_range_get_value_array(const struct linear_range *r, int ranges,
|
||||
unsigned int selector, unsigned int *val);
|
||||
int linear_range_get_selector_low(const struct linear_range *r,
|
||||
unsigned int val, unsigned int *selector,
|
||||
bool *found);
|
||||
int linear_range_get_selector_high(const struct linear_range *r,
|
||||
unsigned int val, unsigned int *selector,
|
||||
bool *found);
|
||||
void linear_range_get_selector_within(const struct linear_range *r,
|
||||
unsigned int val, unsigned int *selector);
|
||||
int linear_range_get_selector_low_array(const struct linear_range *r,
|
||||
int ranges, unsigned int val,
|
||||
unsigned int *selector, bool *found);
|
||||
int linear_range_get_selector_high_array(const struct linear_range *r,
|
||||
int ranges, unsigned int val,
|
||||
unsigned int *selector, bool *found);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user