Some ways to try. Does not guarantee it will be solved.
1st way. Boot into recovery mode, wipe cache, wipe data then factory.
2nd way. When the 1st way doesnt work. Read up well first before performing 2nd way. Download the latest firmware from sammobile. Take note of country and csc code to download. Download latest odin as well. Use odin to flash the downloaded firmware. Caution, wrong step, wrong firmware and/or wrong options selected in odin might/will brick your phone.
If both way fails, pai seh, i dont know liao. Saw some comments like downgrade to 1 version before the latest one. But if the security on the latest firmware is newer than the firmware 1 update before, theres the possibility of soft brick as well.
Please read and understand about firmware flash using odin before trying 2nd way.
Disclaimer. Iam only suggesting about how it might help. Does not guarantee it will not brick your phone.