Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/third_party/rust/rustix/src/ioctl/   (Firefox Browser Version 136.0.1©)  Datei vom 10.2.2025 mit Größe 720 B image not shown  

Quelle  bsd.rs

  Sprache: Rust
 

//! `ioctl` opcode behavior for BSD platforms.

use super::{Direction, RawOpcode};

pub(superconst fn compose_opcode(
    dir: Direction,
    group: RawOpcode,
    num: RawOpcode,
    size: RawOpcode,
) -> RawOpcode {
    let dir = match dir {
        Direction::None => NONE,
        Direction::Read => READ,
        Direction::Write => WRITE,
        Direction::ReadWrite => READ | WRITE,
    };

    dir | num | (group << 8) | ((size & IOCPARAM_MASK) << 16)
}

// `IOC_VOID`
pub const NONE: RawOpcode = 0x2000_0000;
// `IOC_OUT` ("out" is from the perspective of the kernel)
pub const READ: RawOpcode = 0x4000_0000;
// `IOC_IN`
pub const WRITE: RawOpcode = 0x8000_0000;
pub const IOCPARAM_MASK: RawOpcode = 0x1FFF;

Messung V0.5 in Prozent
C=80 H=97 G=88

¤ Dauer der Verarbeitung: 0.10 Sekunden  (vorverarbeitet am  2026-06-18) ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.