I assume the output of the comparator will go to 0 Volts when low and to + 5 Volts (=V2) when high.
The upper switch limit will be when the output is high:
The resistor R5 will be parallel to R2.
The voltage at the input will be 5 * R1 / (R2||R5+R1)
The lower switch limit will be when the output is low:
The resistor R5 will be parallel to R1.
The voltage at the input will be 5 * (R1||R5) / (R2 + (R1||R5))
The hysteresys will be the difference between these values.
The calculations I gave will not work.
The comparator has open drain output, so a resistor to the powersupply is needid.
See datasheet.
This resistor will add to the R5 when the high switch voltage is calculated.
To restate what has been said a different way, think in terms of voltage dividers. When the two inputs are at the same voltage, that is when it will switch.
Each leg with 2 resistors will divide the voltages to fixed values, which sets the hysteresis.