M502 will reset all configurable settings to their "factory defaults", which settings are those?
What Marlin does when M502 is called is defined in the configuration_store.cpp file.

It resets:


Max acceleration
Steps per mm
Max feedrate / speed
Min segment time
Acceleration (Normal, Retract, Travel)
Min feedrate
Min travel feedrate
Jerk settings
Junction deviation
Home and SCARA offsets
Hot end offsets
Filament runout sensor distance
Tool change parameters (Swap length, extra prime, prime speed, retract speed, Park 
positions, Z raise)
Backlash correction distances and smoothing parameters
Extensible UI
Magnetic parking extruder settings
ABL (fade height, stored points, nozzle offset, servo angles
Delta calibration data (Height, Endstop offset, radius, rod length, segments per 
second, calibration radius, trim angle)
Dual / triple endstop adjustments
Preheat parameters
PID parameters
self-defined thermistors
LCD contrast
Power loss recovery
Firmware retraction
Filament diameter (for volumetric extrusion)
Endstops (if disabled)
Stepper drivers
Linear advance parameters
Motor currents (digipot)
CNC coordinate system (if selected)
Skew correction parameters
Advance pause filament change lengths