Now, if SCOTUS's QI theory is based on the text of 42 U.S.C. § 1983 then certainly the legislature could change/update/replace the statute with something worded differently.
But it isn't clear that their decision is based on that (or any other) statute at all. Some interpretations of Harlow vs Fitzgerald seem to point more to the idea that SCOTUS decided that this immunity was derived from other aspects of the totality of the constitution, USC and precedent. Others see it more the way you suggest, which is that SCOTUS concluded that QI existed based on specific statutory language.
Apparently, we don't have to wait that long to find out, since they will be reconsidering it starting tomorrow.