Class: Nl::Linux::DrmRas

Inherits:
Genl::Family show all
Defined in:
nl-linux/generated/nl/linux/drm_ras.rb

Overview

DRM RAS (Reliability, Availability, Serviceability) over Generic Netlink. Provides a standardized mechanism for DRM drivers to register "nodes" representing hardware/software components capable of reporting error counters. Userspace tools can query the list of nodes or individual error counters via the Generic Netlink interface.

Defined Under Namespace

Modules: AttributeSets, Enums, Messages, Notifications, Structs Classes: AsyncOperations

Constant Summary collapse

NAME =
"drm-ras"
VERSION =
1

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Genl::Family

version

Class Method Details

.open(resolver: ::Nl::Linux::DEFAULT_RESOLVER, executor: nil, notification_capacity: DEFAULT_NOTIFICATION_CAPACITY) ⇒ DrmRas .open(resolver: ::Nl::Linux::DEFAULT_RESOLVER, executor: nil, notification_capacity: DEFAULT_NOTIFICATION_CAPACITY) {|family| ... } ⇒ Object

Overloads:

  • .open(resolver: ::Nl::Linux::DEFAULT_RESOLVER, executor: nil, notification_capacity: DEFAULT_NOTIFICATION_CAPACITY) ⇒ DrmRas

    Parameters:

    • resolver (#call) (defaults to: ::Nl::Linux::DEFAULT_RESOLVER)
    • executor (Symbol, nil) (defaults to: nil)
    • notification_capacity (Integer, nil) (defaults to: DEFAULT_NOTIFICATION_CAPACITY)

    Returns:

  • .open(resolver: ::Nl::Linux::DEFAULT_RESOLVER, executor: nil, notification_capacity: DEFAULT_NOTIFICATION_CAPACITY) {|family| ... } ⇒ Object

    Returns the result of the block.

    Parameters:

    • resolver (#call) (defaults to: ::Nl::Linux::DEFAULT_RESOLVER)
    • executor (Symbol, nil) (defaults to: nil)
    • notification_capacity (Integer, nil) (defaults to: DEFAULT_NOTIFICATION_CAPACITY)

    Yield Parameters:

    Returns:

    • (Object) —

      the result of the block



26
27
28
# File 'nl-linux/generated/nl/linux/drm_ras.rb', line 26

def self.open(resolver: ::Nl::Linux::DEFAULT_RESOLVER, executor: nil, notification_capacity: DEFAULT_NOTIFICATION_CAPACITY)
  super
end

Instance Method Details

#async(stream_capacity: nil) ⇒ AsyncOperations

Returns the asynchronous operation facade for this family.

Parameters:

  • stream_capacity (::Integer, nil) (defaults to: nil)

Returns:



466
467
468
469
# File 'nl-linux/generated/nl/linux/drm_ras.rb', line 466

def async(stream_capacity: nil)
  return @async_operations ||= build_async_facade(AsyncOperations) if stream_capacity.nil?
  build_async_facade(AsyncOperations, stream_capacity:)
end

#do_clear_error_counter(**args) ⇒ void

This method returns an undefined value.

Clear error counter for a given node. The request includes the error-id and node-id of the counter to be cleared.

Requires CAP_NET_ADMIN in the initial user namespace.

Parameters:

  • args (Hash)

Options Hash (**args):

  • node_id (Integer) —

    Node ID targeted by this error counter operation.

  • error_id (Integer) —

    Unique identifier for a specific error counter within an node.

See Also:



408
409
410
# File 'nl-linux/generated/nl/linux/drm_ras.rb', line 408

def do_clear_error_counter(**args)
  exchange_message(:"do", Messages::DoClearErrorCounterRequest, nil, args)
end

#do_get_error_counter(**args) ⇒ Messages::DoGetErrorCounterReply

Retrieve error counter for a given node. The response includes the id, the name, and even the current value of each counter.

Requires CAP_NET_ADMIN in the initial user namespace.

Parameters:

  • args (Hash)

Options Hash (**args):

  • node_id (Integer) —

    Node ID targeted by this error counter operation.

  • error_id (Integer) —

    Unique identifier for a specific error counter within an node.

Returns:

See Also:



376
377
378
# File 'nl-linux/generated/nl/linux/drm_ras.rb', line 376

def do_get_error_counter(**args)
  exchange_message(:"do", Messages::DoGetErrorCounterRequest, Messages::DoGetErrorCounterReply, args)
end

#dump_get_error_counter(**args) ⇒ Array<Messages::DumpGetErrorCounterReply> #dump_get_error_counter(**args) {|reply| ... } ⇒ void

Retrieve error counter for a given node. The response includes the id, the name, and even the current value of each counter.

Requires CAP_NET_ADMIN in the initial user namespace.

Overloads:

  • #dump_get_error_counter(**args) ⇒ Array<Messages::DumpGetErrorCounterReply>

    Returns an array when no block is given.

    Parameters:

    • args (Hash)

    Options Hash (**args):

    • node_id (Integer) —

      Node ID targeted by this error counter operation.

    Returns:

  • #dump_get_error_counter(**args) {|reply| ... } ⇒ void

    This method returns an undefined value.

    Yields each reply when a block is given.

    Parameters:

    • args (Hash)

    Options Hash (**args):

    • node_id (Integer) —

      Node ID targeted by this error counter operation.

    Yield Parameters:

See Also:



396
397
398
# File 'nl-linux/generated/nl/linux/drm_ras.rb', line 396

def dump_get_error_counter(**args, &block)
  exchange_message(:"dump", Messages::DumpGetErrorCounterRequest, Messages::DumpGetErrorCounterReply, args, &block)
end

#dump_list_nodes(**args) ⇒ Array<Messages::DumpListNodesReply> #dump_list_nodes(**args) {|reply| ... } ⇒ void

Retrieve the full list of currently registered DRM RAS nodes. Each node includes its dynamically assigned ID, name, and type. Important: User space must call this operation first to obtain the node IDs. These IDs are required for all subsequent operations on nodes, such as querying error counters.

Requires CAP_NET_ADMIN in the initial user namespace.

Overloads:

See Also:



364
365
366
# File 'nl-linux/generated/nl/linux/drm_ras.rb', line 364

def dump_list_nodes(**args, &block)
  exchange_message(:"dump", Messages::DumpListNodesRequest, Messages::DumpListNodesReply, args, &block)
end