That "filter failed" message is issued by CUPS, the Mac Printer spooler. The scripts used to process the data files for Printing are called "filters".
The issue with some other Printers is that the Drivers were signed with certificates that have since expired, and a new download (regardless of version) was required to update the authentication certificates.
This page at Lexmark indicates that the Printer driver for network connected printer was updated 18 March, 2021.
If your pinter driver package is older than that DATE, you should delete it and the printer instance, then add a new Printer, which should fetch a new copy of the Driver package automatically. Alternatively you could delete your Printer instance and download and install the newer-dated version manually.
https://www.lexmark.com/en_us/printer/7703/Lexmark-MX310dn
.