Milan powerbrokers have made it no secret they'd love to re-sign the Brazilian.
"When he went to Madrid I was moved," Galliani told Sky Sport 24 on Tuesday.
The official added: "We would have to sign Kaka permanently, otherwise, due to the Spanish fiscal system, a loan move would create huge cost problems.
“Kaka can only move on loan within Spain. For us to sign him would mean doing so permanently and not on loan.
“I'm sorry to disappoint the fans, but the Kaka hypothesis is unfeasible.”