tools/testing/selftests/hid/tests/test_multitouch.py
Source file repositories/reference/linux-study-clean/tools/testing/selftests/hid/tests/test_multitouch.py
File Facts
- System
- Linux kernel
- Corpus path
tools/testing/selftests/hid/tests/test_multitouch.py- Extension
.py- Size
- 235079 bytes
- Lines
- 2179
- Domain
- Support Tooling And Documentation
- Bucket
- tools
- Inferred role
- Support Tooling And Documentation: tools
- Status
- atlas-only
Why This File Exists
Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
- Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.
Dependency Surface
- No C-style include directives detected by the generator.
Detected Declarations
function BIT
Annotated Snippet
#!/bin/env python3
# SPDX-License-Identifier: GPL-2.0
# -*- coding: utf-8 -*-
#
# Copyright (c) 2017 Benjamin Tissoires <benjamin.tissoires@gmail.com>
# Copyright (c) 2017 Red Hat, Inc.
#
from . import base
from hidtools.hut import HUT
from hidtools.util import BusType
import enum
import libevdev
import logging
import pytest
import sys
import time
logger = logging.getLogger("hidtools.test.multitouch")
KERNEL_MODULE = base.KernelModule("hid-multitouch", "hid_multitouch")
def BIT(x):
return 1 << x
mt_quirks = {
"NOT_SEEN_MEANS_UP": BIT(0),
"SLOT_IS_CONTACTID": BIT(1),
"CYPRESS": BIT(2),
"SLOT_IS_CONTACTNUMBER": BIT(3),
"ALWAYS_VALID": BIT(4),
"VALID_IS_INRANGE": BIT(5),
"VALID_IS_CONFIDENCE": BIT(6),
"CONFIDENCE": BIT(7),
"SLOT_IS_CONTACTID_MINUS_ONE": BIT(8),
"NO_AREA": BIT(9),
"IGNORE_DUPLICATES": BIT(10),
"HOVERING": BIT(11),
"CONTACT_CNT_ACCURATE": BIT(12),
"FORCE_GET_FEATURE": BIT(13),
"FIX_CONST_CONTACT_ID": BIT(14),
"TOUCH_SIZE_SCALING": BIT(15),
"STICKY_FINGERS": BIT(16),
"ASUS_CUSTOM_UP": BIT(17),
"WIN8_PTP_BUTTONS": BIT(18),
"SEPARATE_APP_REPORT": BIT(19),
"MT_QUIRK_FORCE_MULTI_INPUT": BIT(20),
}
class Data(object):
pass
class Touch(object):
def __init__(self, id, x, y):
self.contactid = id
self.x = x
self.y = y
self.cx = x
self.cy = y
self.tipswitch = True
self.confidence = True
self.tippressure = 15
self.azimuth = 0
self.inrange = True
self.width = 10
self.height = 10
Annotation
- Detected declarations: `function BIT`.
- Atlas domain: Support Tooling And Documentation / tools.
- Implementation status: atlas-only.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.