Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
grupal-2c2024 grupal-2c2024
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Metrics
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Package Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • juan diego figari
  • grupal-2c2024grupal-2c2024
  • Issues
  • #16

Closed
Open
Created Oct 30, 2024 by Ignacio Ianello@iianelloMaintainer

General Protection - TPSP - Tareas - Segunda parte

Buenas! estamos teniendo un GP cuando hacemos el jump a la tarea IDLE,de las posibles causas que generan un GP (Adjunto abajo) puede ser un error de segmento o un acceso a descriptor nulo.

Intentamos debuggear con GDB la razón de la excepción y vimos si teniamos algun tema con los privilegios de la tarea,pero no nos llamo nada la atención.(especialmente cuando la diapo de la materia hace lo mismo que aca)

Adjunto vinculos relevantes

https://gitlab.exactas.uba.ar/jfigari/grupal-2c2024/-/blob/master/TPSP/src/kernel.asm#L231

https://gitlab.exactas.uba.ar/jfigari/grupal-2c2024/-/blob/master/TPSP/src/tss.c#L37

General Protection Fault

A General Protection Fault may occur for various reasons. The most common are:

-Segment error (privilege, type, limit, read/write rights).

-Executing a privileged instruction while CPL != 0.

-Writing a 1 in a reserved register field or writing invalid value combinations (e.g. CR0 with PE=0 and PG=1).

-Referencing or accessing a null-descriptor.

-Accessing a memory address with bits 48-63 not matching bit 47 (e.g. 0x_0000_8000_0000_0000 instead of 0x_ffff_8000_0000_0000) in 64 bit mode.

-Executing an instruction that requires memory operands to be aligned (e.g. movaps) without the proper alignment.

The saved instruction pointer points to the instruction which caused the exception.

Error code: The General Protection Fault sets an error code, which is the segment selector index when the exception is segment related. Otherwise, 0.

@bventrici @mcervetto @ccarboni @jfigari @iianello

Edited Oct 30, 2024 by Ignacio Ianello
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking