I ended up dropping the brickfield tables, after which the upgrade ran without error. Why and how those tables were there in the first place will remain unsolved.
Installing and upgrading help
attempt to create mdl_tool_brickfield* tables twice
This discussion has been locked so you can no longer reply to it.